3v4l.org

run code in 500+ PHP versions simultaneously
<?php function demo($array) { $debug_backtrace = []; foreach ($array as $key => &$value) { echo "{$value}\r\n"; if ($value == 3) { unset($array[$key]); continue; } $debug_backtrace[] = debug_backtrace(DEBUG_BACKTRACE_IGNORE_ARGS); } } demo([1, 2, 3]);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/hYN2r
function name:  (null)
number of ops:  4
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   19     0  E >   INIT_FCALL                                                   'demo'
          1        SEND_VAL                                                     <array>
          2        DO_FCALL                                          0          
          3      > RETURN                                                       1

Function demo:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 125) Position 1 = 3, Position 2 = 18
Branch analysis from position: 3
2 jumps found. (Code = 126) Position 1 = 4, Position 2 = 18
Branch analysis from position: 4
2 jumps found. (Code = 43) Position 1 = 10, Position 2 = 12
Branch analysis from position: 10
1 jumps found. (Code = 42) Position 1 = 3
Branch analysis from position: 3
Branch analysis from position: 12
1 jumps found. (Code = 42) Position 1 = 3
Branch analysis from position: 3
Branch analysis from position: 18
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 18
filename:       /in/hYN2r
function name:  demo
number of ops:  20
compiled vars:  !0 = $array, !1 = $debug_backtrace, !2 = $value, !3 = $key
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    3     0  E >   RECV                                                 !0      
    4     1        ASSIGN                                                       !1, <array>
    6     2      > FE_RESET_RW                                          $5      !0, ->18
          3    > > FE_FETCH_RW                                          ~6      $5, !2, ->18
          4    >   ASSIGN                                                       !3, ~6
    7     5        NOP                                                          
          6        FAST_CONCAT                                          ~8      !2, '%0D%0A'
          7        ECHO                                                         ~8
    9     8        IS_EQUAL                                                     !2, 3
          9      > JMPZ                                                         ~9, ->12
   10    10    >   UNSET_DIM                                                    !0, !3
   12    11      > JMP                                                          ->3
   15    12    >   INIT_FCALL                                                   'debug_backtrace'
         13        SEND_VAL                                                     2
         14        DO_ICALL                                             $11     
         15        ASSIGN_DIM                                                   !1
         16        OP_DATA                                                      $11
    6    17      > JMP                                                          ->3
         18    >   FE_FREE                                                      $5
   17    19      > RETURN                                                       null

End of function demo

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
128.64 ms | 481 KiB | 9 Q