3v4l.org

run code in 300+ PHP versions simultaneously
<?php function reverseOrder($arr1) { if (is_array($arr1)) { return array_reverse($arr1); } return false; } $reversedArray = reverseOrder(array(1,4,2,5,19,11,28)); echo(implode(', ', $reversedArray)); ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/0WKJY
function name:  (null)
number of ops:  10
compiled vars:  !0 = $reversedArray
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   11     0  E >   INIT_FCALL                                               'reverseorder'
          1        SEND_VAL                                                 <array>
          2        DO_FCALL                                      0  $1      
          3        ASSIGN                                                   !0, $1
   13     4        INIT_FCALL                                               'implode'
          5        SEND_VAL                                                 '%2C+'
          6        SEND_VAR                                                 !0
          7        DO_ICALL                                         $3      
          8        ECHO                                                     $3
   14     9      > RETURN                                                   1

Function reverseorder:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 3, Position 2 = 7
Branch analysis from position: 3
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 7
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/0WKJY
function name:  reverseOrder
number of ops:  9
compiled vars:  !0 = $arr1
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
    4     1        TYPE_CHECK                                  128          !0
          2      > JMPZ                                                     ~1, ->7
    5     3    >   INIT_FCALL                                               'array_reverse'
          4        SEND_VAR                                                 !0
          5        DO_ICALL                                         $2      
          6      > RETURN                                                   $2
    8     7    > > RETURN                                                   <false>
    9     8*     > RETURN                                                   null

End of function reverseorder

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
186.86 ms | 1397 KiB | 18 Q