3v4l.org

run code in 300+ PHP versions simultaneously
<?php $input = array(1,2,3,4,5); while($input) { array_splice($input, 0, 2); print_r($input); }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 10
Branch analysis from position: 10
2 jumps found. (Code = 44) Position 1 = 11, Position 2 = 2
Branch analysis from position: 11
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 2
2 jumps found. (Code = 44) Position 1 = 11, Position 2 = 2
Branch analysis from position: 11
Branch analysis from position: 2
filename:       /in/NnHZu
function name:  (null)
number of ops:  12
compiled vars:  !0 = $input
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, <array>
    4     1      > JMP                                                      ->10
    5     2    >   INIT_FCALL                                               'array_splice'
          3        SEND_REF                                                 !0
          4        SEND_VAL                                                 0
          5        SEND_VAL                                                 2
          6        DO_ICALL                                                 
    6     7        INIT_FCALL                                               'print_r'
          8        SEND_VAR                                                 !0
          9        DO_ICALL                                                 
    4    10    > > JMPNZ                                                    !0, ->2
    7    11    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
164.39 ms | 1394 KiB | 17 Q