3v4l.org

run code in 300+ PHP versions simultaneously
<?php function sum($a, $b) { return $a + $b; } sum(12, 34); sum(1, 2); sum(3, 4); $num1 = 123; $num2 = 456; var_dump(sum($num1, $num2));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/qpsq7
function name:  (null)
number of ops:  22
compiled vars:  !0 = $num1, !1 = $num2
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   INIT_FCALL                                               'sum'
          1        SEND_VAL                                                 12
          2        SEND_VAL                                                 34
          3        DO_FCALL                                      0          
    8     4        INIT_FCALL                                               'sum'
          5        SEND_VAL                                                 1
          6        SEND_VAL                                                 2
          7        DO_FCALL                                      0          
    9     8        INIT_FCALL                                               'sum'
          9        SEND_VAL                                                 3
         10        SEND_VAL                                                 4
         11        DO_FCALL                                      0          
   11    12        ASSIGN                                                   !0, 123
   12    13        ASSIGN                                                   !1, 456
   14    14        INIT_FCALL                                               'var_dump'
         15        INIT_FCALL                                               'sum'
         16        SEND_VAR                                                 !0
         17        SEND_VAR                                                 !1
         18        DO_FCALL                                      0  $7      
         19        SEND_VAR                                                 $7
         20        DO_ICALL                                                 
         21      > RETURN                                                   1

Function sum:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/qpsq7
function name:  sum
number of ops:  5
compiled vars:  !0 = $a, !1 = $b
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
          1        RECV                                             !1      
    4     2        ADD                                              ~2      !0, !1
          3      > RETURN                                                   ~2
    5     4*     > RETURN                                                   null

End of function sum

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
184.54 ms | 1398 KiB | 19 Q