3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = []; for ($i=0; $i<1000000; $i++) { $a = []; $a[0]=1; if ($i % 500 === 0) echo memory_get_usage(),PHP_EOL; }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 14
Branch analysis from position: 14
2 jumps found. (Code = 44) Position 1 = 16, Position 2 = 3
Branch analysis from position: 16
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 3
2 jumps found. (Code = 43) Position 1 = 9, Position 2 = 13
Branch analysis from position: 9
2 jumps found. (Code = 44) Position 1 = 16, Position 2 = 3
Branch analysis from position: 16
Branch analysis from position: 3
Branch analysis from position: 13
filename:       /in/iBD8P
function name:  (null)
number of ops:  17
compiled vars:  !0 = $a, !1 = $i
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
    4     1        ASSIGN                                                   !1, 0
          2      > JMP                                                      ->14
    5     3    >   ASSIGN                                                   !0, <array>
    6     4        ASSIGN_DIM                                               !0, 0
          5        OP_DATA                                                  1
    7     6        MOD                                              ~6      !1, 500
          7        IS_IDENTICAL                                             ~6, 0
          8      > JMPZ                                                     ~7, ->13
          9    >   INIT_FCALL                                               'memory_get_usage'
         10        DO_ICALL                                         $8      
         11        ECHO                                                     $8
         12        ECHO                                                     '%0A'
    4    13    >   PRE_INC                                                  !1
         14    >   IS_SMALLER                                               !1, 1000000
         15      > JMPNZ                                                    ~10, ->3
    8    16    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
143.81 ms | 1395 KiB | 15 Q