3v4l.org

run code in 300+ PHP versions simultaneously
<?php $arr = array('a', 'b', 'c'); $len = $len=count($arr); for($i=0; $i<$len; $i++) { echo $arr[$i]; } $arr = array('a', 'b', 'c'); for($i=0; $i<count($arr); $i++) { echo $arr[$i]; }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 9
Branch analysis from position: 9
2 jumps found. (Code = 44) Position 1 = 11, Position 2 = 6
Branch analysis from position: 11
1 jumps found. (Code = 42) Position 1 = 17
Branch analysis from position: 17
2 jumps found. (Code = 44) Position 1 = 20, Position 2 = 14
Branch analysis from position: 20
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 14
2 jumps found. (Code = 44) Position 1 = 20, Position 2 = 14
Branch analysis from position: 20
Branch analysis from position: 14
Branch analysis from position: 6
2 jumps found. (Code = 44) Position 1 = 11, Position 2 = 6
Branch analysis from position: 11
Branch analysis from position: 6
filename:       /in/ePraR
function name:  (null)
number of ops:  21
compiled vars:  !0 = $arr, !1 = $len, !2 = $i
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, <array>
    3     1        COUNT                                            ~4      !0
          2        ASSIGN                                           ~5      !1, ~4
          3        ASSIGN                                                   !1, ~5
    4     4        ASSIGN                                                   !2, 0
          5      > JMP                                                      ->9
    5     6    >   FETCH_DIM_R                                      ~8      !0, !2
          7        ECHO                                                     ~8
    4     8        PRE_INC                                                  !2
          9    >   IS_SMALLER                                               !2, !1
         10      > JMPNZ                                                    ~10, ->6
    8    11    >   ASSIGN                                                   !0, <array>
    9    12        ASSIGN                                                   !2, 0
         13      > JMP                                                      ->17
   10    14    >   FETCH_DIM_R                                      ~13     !0, !2
         15        ECHO                                                     ~13
    9    16        PRE_INC                                                  !2
         17    >   COUNT                                            ~15     !0
         18        IS_SMALLER                                               !2, ~15
         19      > JMPNZ                                                    ~16, ->14
   11    20    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
164.55 ms | 1394 KiB | 13 Q