3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = ['a' => 1, 'b' => 2, 'c' => 3]; $b = new stdClass(); $b->a = 1; $b->b = 2; $b->c = 3; echo microtime(true), PHP_EOL; for ($i = 0; $i < 100000; $i++) { $a['a']; } echo microtime(true), PHP_EOL; for ($i = 0; $i < 100000; $i++) { $b->a; } echo microtime(true), PHP_EOL;
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 = 17
Branch analysis from position: 22
1 jumps found. (Code = 42) Position 1 = 32
Branch analysis from position: 32
2 jumps found. (Code = 44) Position 1 = 34, Position 2 = 29
Branch analysis from position: 34
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 29
2 jumps found. (Code = 44) Position 1 = 34, Position 2 = 29
Branch analysis from position: 34
Branch analysis from position: 29
Branch analysis from position: 17
2 jumps found. (Code = 44) Position 1 = 22, Position 2 = 17
Branch analysis from position: 22
Branch analysis from position: 17
filename:       /in/cnorY
function name:  (null)
number of ops:  40
compiled vars:  !0 = $a, !1 = $b, !2 = $i
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
    4     1        NEW                                              $4      'stdClass'
          2        DO_FCALL                                      0          
          3        ASSIGN                                                   !1, $4
    5     4        ASSIGN_OBJ                                               !1, 'a'
          5        OP_DATA                                                  1
    6     6        ASSIGN_OBJ                                               !1, 'b'
          7        OP_DATA                                                  2
    7     8        ASSIGN_OBJ                                               !1, 'c'
          9        OP_DATA                                                  3
   10    10        INIT_FCALL                                               'microtime'
         11        SEND_VAL                                                 <true>
         12        DO_ICALL                                         $10     
         13        ECHO                                                     $10
         14        ECHO                                                     '%0A'
   11    15        ASSIGN                                                   !2, 0
         16      > JMP                                                      ->20
   12    17    >   FETCH_DIM_R                                      ~12     !0, 'a'
         18        FREE                                                     ~12
   11    19        PRE_INC                                                  !2
         20    >   IS_SMALLER                                               !2, 100000
         21      > JMPNZ                                                    ~14, ->17
   14    22    >   INIT_FCALL                                               'microtime'
         23        SEND_VAL                                                 <true>
         24        DO_ICALL                                         $15     
         25        ECHO                                                     $15
         26        ECHO                                                     '%0A'
   15    27        ASSIGN                                                   !2, 0
         28      > JMP                                                      ->32
   16    29    >   FETCH_OBJ_R                                      ~17     !1, 'a'
         30        FREE                                                     ~17
   15    31        PRE_INC                                                  !2
         32    >   IS_SMALLER                                               !2, 100000
         33      > JMPNZ                                                    ~19, ->29
   18    34    >   INIT_FCALL                                               'microtime'
         35        SEND_VAL                                                 <true>
         36        DO_ICALL                                         $20     
         37        ECHO                                                     $20
         38        ECHO                                                     '%0A'
         39      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
148.13 ms | 1400 KiB | 15 Q