3v4l.org

run code in 300+ PHP versions simultaneously
<?php function f() { $e = new Exception(); if (rand() % 100 == 42) { throw $e; } else { return $e; } } throw f();
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 108) Position 1 = -2
filename:       /in/7P5Z5
function name:  (null)
number of ops:  4
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   12     0  E >   INIT_FCALL                                               'f'
          1        DO_FCALL                                      0  $0      
          2      > THROW                                         0          $0
          3*     > RETURN                                                   1

Function f:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 8, Position 2 = 10
Branch analysis from position: 8
1 jumps found. (Code = 108) Position 1 = -2
Branch analysis from position: 10
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/7P5Z5
function name:  f
number of ops:  12
compiled vars:  !0 = $e
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   NEW                                              $1      'Exception'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $1
    5     3        INIT_FCALL                                               'rand'
          4        DO_ICALL                                         $4      
          5        MOD                                              ~5      $4, 100
          6        IS_EQUAL                                                 ~5, 42
          7      > JMPZ                                                     ~6, ->10
    6     8    > > THROW                                         0          !0
          9*       JMP                                                      ->11
    8    10    > > RETURN                                                   !0
   10    11*     > RETURN                                                   null

End of function f

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
148.28 ms | 1397 KiB | 16 Q