3v4l.org

run code in 300+ PHP versions simultaneously
<?php foo(); bar(); if (!function_exists('foo')) { function foo() { echo bar();} } if (!function_exists('bar')) { function bar() { return 'bar';} }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 9, Position 2 = 10
Branch analysis from position: 9
2 jumps found. (Code = 43) Position 1 = 15, Position 2 = 16
Branch analysis from position: 15
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 16
Branch analysis from position: 10
filename:       /in/sMsf6
function name:  (null)
number of ops:  17
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL_BY_NAME                                       'foo'
          1        DO_FCALL                                      0          
    3     2        INIT_FCALL_BY_NAME                                       'bar'
          3        DO_FCALL                                      0          
    4     4        INIT_FCALL                                               'function_exists'
          5        SEND_VAL                                                 'foo'
          6        DO_ICALL                                         $2      
          7        BOOL_NOT                                         ~3      $2
          8      > JMPZ                                                     ~3, ->10
    5     9    >   DECLARE_FUNCTION                                         'foo'
    7    10    >   INIT_FCALL                                               'function_exists'
         11        SEND_VAL                                                 'bar'
         12        DO_ICALL                                         $4      
         13        BOOL_NOT                                         ~5      $4
         14      > JMPZ                                                     ~5, ->16
    8    15    >   DECLARE_FUNCTION                                         'bar'
    9    16    > > RETURN                                                   1

Function %00foo%2Fin%2FsMsf6%3A5%240:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/sMsf6
function name:  foo
number of ops:  4
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   INIT_FCALL_BY_NAME                                       'bar'
          1        DO_FCALL                                      0  $0      
          2        ECHO                                                     $0
          3      > RETURN                                                   null

End of function %00foo%2Fin%2FsMsf6%3A5%240

Function %00bar%2Fin%2FsMsf6%3A8%241:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/sMsf6
function name:  bar
number of ops:  2
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    8     0  E > > RETURN                                                   'bar'
          1*     > RETURN                                                   null

End of function %00bar%2Fin%2FsMsf6%3A8%241

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
155.37 ms | 1396 KiB | 15 Q