3v4l.org

run code in 300+ PHP versions simultaneously
<?php $x = array(1, 2, 3, 4, 5); $len=count($x); echo "array[$len] {"; foreach($x as $key=>$int) echo "[$key] => int[$int]"; echo "}"; unset($x[3]); $x = array_values($x); echo "\n"; $len=count($x); echo "array[$len] {"; foreach($x as $key=>$int) echo "[$key] => int[$int]"; echo "}"; ?>
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 8, Position 2 = 17
Branch analysis from position: 8
2 jumps found. (Code = 78) Position 1 = 9, Position 2 = 17
Branch analysis from position: 9
1 jumps found. (Code = 42) Position 1 = 8
Branch analysis from position: 8
Branch analysis from position: 17
2 jumps found. (Code = 77) Position 1 = 32, Position 2 = 41
Branch analysis from position: 32
2 jumps found. (Code = 78) Position 1 = 33, Position 2 = 41
Branch analysis from position: 33
1 jumps found. (Code = 42) Position 1 = 32
Branch analysis from position: 32
Branch analysis from position: 41
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 41
Branch analysis from position: 17
filename:       /in/vgIKS
function name:  (null)
number of ops:  44
compiled vars:  !0 = $x, !1 = $len, !2 = $int, !3 = $key
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, <array>
    3     1        COUNT                                            ~5      !0
          2        ASSIGN                                                   !1, ~5
    4     3        ROPE_INIT                                     3  ~8      'array%5B'
          4        ROPE_ADD                                      1  ~8      ~8, !1
          5        ROPE_END                                      2  ~7      ~8, '%5D+%7B'
          6        ECHO                                                     ~7
    5     7      > FE_RESET_R                                       $10     !0, ->17
          8    > > FE_FETCH_R                                       ~11     $10, !2, ->17
          9    >   ASSIGN                                                   !3, ~11
    6    10        ROPE_INIT                                     5  ~14     '%5B'
         11        ROPE_ADD                                      1  ~14     ~14, !3
         12        ROPE_ADD                                      2  ~14     ~14, '%5D+%3D%3E+int%5B'
         13        ROPE_ADD                                      3  ~14     ~14, !2
         14        ROPE_END                                      4  ~13     ~14, '%5D'
         15        ECHO                                                     ~13
    5    16      > JMP                                                      ->8
         17    >   FE_FREE                                                  $10
    7    18        ECHO                                                     '%7D'
    8    19        UNSET_DIM                                                !0, 3
    9    20        INIT_FCALL                                               'array_values'
         21        SEND_VAR                                                 !0
         22        DO_ICALL                                         $17     
         23        ASSIGN                                                   !0, $17
   10    24        ECHO                                                     '%0A'
   11    25        COUNT                                            ~19     !0
         26        ASSIGN                                                   !1, ~19
   12    27        ROPE_INIT                                     3  ~22     'array%5B'
         28        ROPE_ADD                                      1  ~22     ~22, !1
         29        ROPE_END                                      2  ~21     ~22, '%5D+%7B'
         30        ECHO                                                     ~21
   13    31      > FE_RESET_R                                       $24     !0, ->41
         32    > > FE_FETCH_R                                       ~25     $24, !2, ->41
         33    >   ASSIGN                                                   !3, ~25
   14    34        ROPE_INIT                                     5  ~28     '%5B'
         35        ROPE_ADD                                      1  ~28     ~28, !3
         36        ROPE_ADD                                      2  ~28     ~28, '%5D+%3D%3E+int%5B'
         37        ROPE_ADD                                      3  ~28     ~28, !2
         38        ROPE_END                                      4  ~27     ~28, '%5D'
         39        ECHO                                                     ~27
   13    40      > JMP                                                      ->32
         41    >   FE_FREE                                                  $24
   15    42        ECHO                                                     '%7D'
   16    43      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
171.89 ms | 1400 KiB | 15 Q