3v4l.org

run code in 300+ PHP versions simultaneously
<?php namespace fred; $strlen="strlen"; for($i=0; $i<3; $i++) { echo strlen("Hello World!"), "\n"; if ($i == 1) { eval ('namespace fred; function strlen($s) { return 2* \strlen($s); }'); } }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 12
Branch analysis from position: 12
2 jumps found. (Code = 44) Position 1 = 14, Position 2 = 3
Branch analysis from position: 14
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 3
2 jumps found. (Code = 43) Position 1 = 10, Position 2 = 11
Branch analysis from position: 10
2 jumps found. (Code = 44) Position 1 = 14, Position 2 = 3
Branch analysis from position: 14
Branch analysis from position: 3
Branch analysis from position: 11
filename:       /in/rSWHu
function name:  (null)
number of ops:  15
compiled vars:  !0 = $strlen, !1 = $i
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, 'strlen'
    4     1        ASSIGN                                                   !1, 0
          2      > JMP                                                      ->12
    5     3    >   INIT_NS_FCALL_BY_NAME                                    'fred%5Cstrlen'
          4        SEND_VAL_EX                                              'Hello+World%21'
          5        DO_FCALL                                      0  $4      
          6        ECHO                                                     $4
          7        ECHO                                                     '%0A'
    6     8        IS_EQUAL                                                 !1, 1
          9      > JMPZ                                                     ~5, ->11
    7    10    >   INCLUDE_OR_EVAL                                          'namespace+fred%3B+function+strlen%28%24s%29+%7B+return+2%2A+%5Cstrlen%28%24s%29%3B+%7D', EVAL
    4    11    >   PRE_INC                                                  !1
         12    >   IS_SMALLER                                               !1, 3
         13      > JMPNZ                                                    ~8, ->3
    9    14    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
143.15 ms | 1395 KiB | 15 Q