3v4l.org

run code in 300+ PHP versions simultaneously
<?php function google($x){function_exists($x)||eval("function $x(){echo strlen($x);}");$x();} google('bing'); google('bing'); google('google');
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/gb1am
function name:  (null)
number of ops:  10
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   INIT_FCALL                                               'google'
          1        SEND_VAL                                                 'bing'
          2        DO_FCALL                                      0          
    6     3        INIT_FCALL                                               'google'
          4        SEND_VAL                                                 'bing'
          5        DO_FCALL                                      0          
    7     6        INIT_FCALL                                               'google'
          7        SEND_VAL                                                 'google'
          8        DO_FCALL                                      0          
          9      > RETURN                                                   1

Function google:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 47) Position 1 = 5, Position 2 = 12
Branch analysis from position: 5
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 12
filename:       /in/gb1am
function name:  google
number of ops:  15
compiled vars:  !0 = $x
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
          1        INIT_FCALL                                               'function_exists'
          2        SEND_VAR                                                 !0
          3        DO_ICALL                                         $1      
          4      > JMPNZ_EX                                         ~2      $1, ->12
          5    >   ROPE_INIT                                     5  ~4      'function+'
          6        ROPE_ADD                                      1  ~4      ~4, !0
          7        ROPE_ADD                                      2  ~4      ~4, '%28%29%7Becho+strlen%28'
          8        ROPE_ADD                                      3  ~4      ~4, !0
          9        ROPE_END                                      4  ~3      ~4, '%29%3B%7D'
         10        INCLUDE_OR_EVAL                                  $7      ~3, EVAL
         11        BOOL                                             ~2      $7
         12    >   INIT_DYNAMIC_CALL                                        !0
         13        DO_FCALL                                      0          
         14      > RETURN                                                   null

End of function google

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
151.71 ms | 1398 KiB | 18 Q