3v4l.org

run code in 200+ PHP versions simultaneously
<?php class Monkey{} $gibbon = new Monkey; $gibbon->name = 'Librarian'; function splort() { global $gibbon; if($gibbon->name == 'Librarian') echo "Ook."; else echo 'Boing!'; } register_shutdown_function('splort'); echo "Time for go to bed.";
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/9k5XJ
function name:  (null)
number of ops:  10
compiled vars:  !0 = $gibbon
line     #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   4     0  E >   NEW                                              $1      :15
         1        DO_FCALL                                      0          
         2        QM_ASSIGN                                                !0
   5     3        ASSIGN_SUB                                    8          !0, 'name'
         4        OP_DATA                                                  'Librarian'
  14     5        INIT_FCALL                                               'register_shutdown_function'
         6        SEND_VAL                                                 'splort'
         7        DO_ICALL                                                 
  16     8        ASSIGN_OBJ                                               'Time+for+go+to+bed.'
         9      > RETURN                                                   1

Function splort:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 4, Position 2 = 6
Branch analysis from position: 4
1 jumps found. (Code = 42) Position 1 = 7
Branch analysis from position: 7
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 6
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/9k5XJ
function name:  splort
number of ops:  8
compiled vars:  !0 = $gibbon
line     #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   9     0  E >   BIND_GLOBAL                                              !0, 'gibbon'
  10     1        FETCH_OBJ_R                                      ~1      !0, 'name'
         2        IS_NOT_EQUAL                                     ~2      ~1, 'Librarian'
         3      > JMPZ                                                     ~2, ->6
         4    >   ASSIGN_OBJ                                               'Ook.'
         5      > JMP                                                      ->7
  11     6    >   ASSIGN_OBJ                                               'Boing%21'
  12     7    > > RETURN                                                   null

End of function splort

Class Monkey: [no user functions]

Generated using Vulcan Logic Dumper, using php 7.4.0