3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Foo { public $var = '3.1415962654'; } $baseMemory = memory_get_usage(); for ( $i = 0; $i <= 100000; $i++ ) { $a = new Foo; $a->self = $a; if ( $i % 500 === 0 ) { echo sprintf( '%8d: ', $i ), memory_get_usage() - $baseMemory, "\n"; } }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 24
Branch analysis from position: 24
2 jumps found. (Code = 44) Position 1 = 26, Position 2 = 5
Branch analysis from position: 26
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 5
2 jumps found. (Code = 43) Position 1 = 13, Position 2 = 23
Branch analysis from position: 13
2 jumps found. (Code = 44) Position 1 = 26, Position 2 = 5
Branch analysis from position: 26
Branch analysis from position: 5
Branch analysis from position: 23
filename:       /in/fguia
function name:  (null)
number of ops:  27
compiled vars:  !0 = $baseMemory, !1 = $i, !2 = $a
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   INIT_FCALL                                               'memory_get_usage'
          1        DO_ICALL                                         $3      
          2        ASSIGN                                                   !0, $3
    9     3        ASSIGN                                                   !1, 0
          4      > JMP                                                      ->24
   11     5    >   NEW                                              $6      'Foo'
          6        DO_FCALL                                      0          
          7        ASSIGN                                                   !2, $6
   12     8        ASSIGN_OBJ                                               !2, 'self'
          9        OP_DATA                                                  !2
   13    10        MOD                                              ~10     !1, 500
         11        IS_IDENTICAL                                             ~10, 0
         12      > JMPZ                                                     ~11, ->23
   15    13    >   INIT_FCALL                                               'sprintf'
         14        SEND_VAL                                                 '%258d%3A+'
         15        SEND_VAR                                                 !1
         16        DO_ICALL                                         $12     
         17        ECHO                                                     $12
         18        INIT_FCALL                                               'memory_get_usage'
         19        DO_ICALL                                         $13     
         20        SUB                                              ~14     $13, !0
         21        ECHO                                                     ~14
         22        ECHO                                                     '%0A'
    9    23    >   PRE_INC                                                  !1
         24    >   IS_SMALLER_OR_EQUAL                                      !1, 100000
         25      > JMPNZ                                                    ~16, ->5
   17    26    > > RETURN                                                   1

Class Foo: [no user functions]

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
149.84 ms | 1396 KiB | 17 Q