3v4l.org

run code in 300+ PHP versions simultaneously
<?php $list = newarray(1,2,3,4,5,6,7,8,9); $total = 0; for ($i=0; $i<= 9; $i++) { $total = $total + $list[i]; } ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 20
Branch analysis from position: 20
2 jumps found. (Code = 44) Position 1 = 22, Position 2 = 15
Branch analysis from position: 22
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 15
2 jumps found. (Code = 44) Position 1 = 22, Position 2 = 15
Branch analysis from position: 22
Branch analysis from position: 15
filename:       /in/PS4XW
function name:  (null)
number of ops:  23
compiled vars:  !0 = $list, !1 = $total, !2 = $i
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL_BY_NAME                                       'newarray'
          1        SEND_VAL_EX                                              1
          2        SEND_VAL_EX                                              2
          3        SEND_VAL_EX                                              3
          4        SEND_VAL_EX                                              4
          5        SEND_VAL_EX                                              5
          6        SEND_VAL_EX                                              6
          7        SEND_VAL_EX                                              7
          8        SEND_VAL_EX                                              8
          9        SEND_VAL_EX                                              9
         10        DO_FCALL                                      0  $3      
         11        ASSIGN                                                   !0, $3
    3    12        ASSIGN                                                   !1, 0
    4    13        ASSIGN                                                   !2, 0
         14      > JMP                                                      ->20
    5    15    >   FETCH_CONSTANT                                   ~7      'i'
         16        FETCH_DIM_R                                      ~8      !0, ~7
         17        ADD                                              ~9      !1, ~8
         18        ASSIGN                                                   !1, ~9
    4    19        PRE_INC                                                  !2
         20    >   IS_SMALLER_OR_EQUAL                                      !2, 9
         21      > JMPNZ                                                    ~12, ->15
    7    22    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
168.18 ms | 1394 KiB | 13 Q