3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = array(); $a['10'] = 'abc'; $a['a'] = 'cde'; foreach ($a as $k=>$v) { if ($k === '10') { echo "found"; } }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 6, Position 2 = 12
Branch analysis from position: 6
2 jumps found. (Code = 78) Position 1 = 7, Position 2 = 12
Branch analysis from position: 7
2 jumps found. (Code = 43) Position 1 = 10, Position 2 = 11
Branch analysis from position: 10
1 jumps found. (Code = 42) Position 1 = 6
Branch analysis from position: 6
Branch analysis from position: 11
Branch analysis from position: 12
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 12
filename:       /in/sm3Vh
function name:  (null)
number of ops:  14
compiled vars:  !0 = $a, !1 = $v, !2 = $k
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
    4     1        ASSIGN_DIM                                               !0, 10
          2        OP_DATA                                                  'abc'
    5     3        ASSIGN_DIM                                               !0, 'a'
          4        OP_DATA                                                  'cde'
    7     5      > FE_RESET_R                                       $6      !0, ->12
          6    > > FE_FETCH_R                                       ~7      $6, !1, ->12
          7    >   ASSIGN                                                   !2, ~7
    8     8        IS_IDENTICAL                                             !2, '10'
          9      > JMPZ                                                     ~9, ->11
    9    10    >   ECHO                                                     'found'
    7    11    > > JMP                                                      ->6
         12    >   FE_FREE                                                  $6
   11    13      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
159.78 ms | 1393 KiB | 13 Q