3v4l.org

run code in 300+ PHP versions simultaneously
<?php ini_set('display_errors', true); error_reporting(E_ALL); $array = [1,2,3,4,5]; foreach ($array as $el) { var_dump($el); var_dump(end($array)); }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 9, Position 2 = 20
Branch analysis from position: 9
2 jumps found. (Code = 78) Position 1 = 10, Position 2 = 20
Branch analysis from position: 10
1 jumps found. (Code = 42) Position 1 = 9
Branch analysis from position: 9
Branch analysis from position: 20
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 20
filename:       /in/ecAFC
function name:  (null)
number of ops:  22
compiled vars:  !0 = $array, !1 = $el
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL                                               'ini_set'
          1        SEND_VAL                                                 'display_errors'
          2        SEND_VAL                                                 <true>
          3        DO_ICALL                                                 
    3     4        INIT_FCALL                                               'error_reporting'
          5        SEND_VAL                                                 32767
          6        DO_ICALL                                                 
    5     7        ASSIGN                                                   !0, <array>
    6     8      > FE_RESET_R                                       $5      !0, ->20
          9    > > FE_FETCH_R                                               $5, !1, ->20
    7    10    >   INIT_FCALL                                               'var_dump'
         11        SEND_VAR                                                 !1
         12        DO_ICALL                                                 
    8    13        INIT_FCALL                                               'var_dump'
         14        INIT_FCALL                                               'end'
         15        SEND_REF                                                 !0
         16        DO_ICALL                                         $7      
         17        SEND_VAR                                                 $7
         18        DO_ICALL                                                 
    6    19      > JMP                                                      ->9
         20    >   FE_FREE                                                  $5
    9    21      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
158.06 ms | 1395 KiB | 21 Q