3v4l.org

run code in 300+ PHP versions simultaneously
<?php function a() { try { throw new Exception('base exception'); } catch (Throwable $t) { throw new Exception('event exception'); } finally { return $t->getMessage(); } } echo a();
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/ud0Dn
function name:  (null)
number of ops:  4
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   12     0  E >   INIT_FCALL                                               'a'
          1        DO_FCALL                                      0  $0      
          2        ECHO                                                     $0
          3      > RETURN                                                   1

Function a:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 108) Position 1 = -2
Found catch point at position: 5
Branch analysis from position: 5
2 jumps found. (Code = 107) Position 1 = 6, Position 2 = -2
Branch analysis from position: 6
1 jumps found. (Code = 108) Position 1 = -2
filename:       /in/ud0Dn
function name:  a
number of ops:  18
compiled vars:  !0 = $t
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   NEW                                              $2      'Exception'
          1        SEND_VAL_EX                                              'base+exception'
          2        DO_FCALL                                      0          
          3      > THROW                                         0          $2
          4*       JMP                                                      ->10
    6     5  E > > CATCH                                       last         'Throwable'
    7     6    >   NEW                                              $4      'Exception'
          7        SEND_VAL_EX                                              'event+exception'
          8        DO_FCALL                                      0          
          9      > THROW                                         0          $4
    8    10*       FAST_CALL                                                ->12
         11*       JMP                                                      ->17
    9    12*       INIT_METHOD_CALL                                         !0, 'getMessage'
         13*       DO_FCALL                                      0  $6      
         14*       DISCARD_EXCEPTION                                        
         15*       RETURN                                                   $6
         16*       FAST_RET                                                 
   11    17*     > RETURN                                                   null

End of function a

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
239.58 ms | 1016 KiB | 14 Q