3v4l.org

run code in 300+ PHP versions simultaneously
<?php $arr = []; for ($i=0; $i<100000; $i++) { $arr[] = ['code' => 123 . $i, 'ipn' => 'ipn-12345']; } $result = []; foreach ($arr as $entry) { $result[$entry['code']] = $entry; } unset($entry); echo count($arr); echo '-' . count($result); //print_r($arr);
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 = 3
Branch analysis from position: 11
2 jumps found. (Code = 77) Position 1 = 13, Position 2 = 18
Branch analysis from position: 13
2 jumps found. (Code = 78) Position 1 = 14, Position 2 = 18
Branch analysis from position: 14
1 jumps found. (Code = 42) Position 1 = 13
Branch analysis from position: 13
Branch analysis from position: 18
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 18
Branch analysis from position: 3
2 jumps found. (Code = 44) Position 1 = 11, Position 2 = 3
Branch analysis from position: 11
Branch analysis from position: 3
filename:       /in/m6WCm
function name:  (null)
number of ops:  26
compiled vars:  !0 = $arr, !1 = $i, !2 = $result, !3 = $entry
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
    4     1        ASSIGN                                                   !1, 0
          2      > JMP                                                      ->9
    5     3    >   CONCAT                                           ~7      '123', !1
          4        INIT_ARRAY                                       ~8      ~7, 'code'
          5        ADD_ARRAY_ELEMENT                                ~8      'ipn-12345', 'ipn'
          6        ASSIGN_DIM                                               !0
          7        OP_DATA                                                  ~8
    4     8        PRE_INC                                                  !1
          9    >   IS_SMALLER                                               !1, 100000
         10      > JMPNZ                                                    ~10, ->3
    9    11    >   ASSIGN                                                   !2, <array>
   10    12      > FE_RESET_R                                       $12     !0, ->18
         13    > > FE_FETCH_R                                               $12, !3, ->18
   11    14    >   FETCH_DIM_R                                      ~13     !3, 'code'
         15        ASSIGN_DIM                                               !2, ~13
         16        OP_DATA                                                  !3
   10    17      > JMP                                                      ->13
         18    >   FE_FREE                                                  $12
   13    19        UNSET_CV                                                 !3
   14    20        COUNT                                            ~15     !0
         21        ECHO                                                     ~15
   15    22        COUNT                                            ~16     !2
         23        CONCAT                                           ~17     '-', ~16
         24        ECHO                                                     ~17
   16    25      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
154.05 ms | 1395 KiB | 13 Q