3v4l.org

run code in 300+ PHP versions simultaneously
<?php function notEquals($expected, $value, string $message = '') { if ($expected != $value) { throw new \Exception('Assertion! ' . ($message ? $message : ($value . ' did not equal ' . $expected))); } } $x = 123; assert(notEquals(1, $x));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/53AgE
function name:  (null)
number of ops:  11
compiled vars:  !0 = $x
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    9     0  E >   ASSIGN                                                   !0, 123
   10     1        ASSERT_CHECK                                             
          2        INIT_FCALL                                               'assert'
          3        INIT_FCALL                                               'notequals'
          4        SEND_VAL                                                 1
          5        SEND_VAR                                                 !0
          6        DO_FCALL                                      0  $2      
          7        SEND_VAR                                                 $2
          8        SEND_VAL                                                 'assert%28notEquals%281%2C+%24x%29%29'
          9        DO_ICALL                                                 
         10      > RETURN                                                   1

Function notequals:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 5, Position 2 = 16
Branch analysis from position: 5
2 jumps found. (Code = 43) Position 1 = 7, Position 2 = 9
Branch analysis from position: 7
1 jumps found. (Code = 42) Position 1 = 12
Branch analysis from position: 12
1 jumps found. (Code = 108) Position 1 = -2
Branch analysis from position: 9
1 jumps found. (Code = 108) Position 1 = -2
Branch analysis from position: 16
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/53AgE
function name:  notEquals
number of ops:  17
compiled vars:  !0 = $expected, !1 = $value, !2 = $message
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
          1        RECV                                             !1      
          2        RECV_INIT                                        !2      ''
    4     3        IS_NOT_EQUAL                                             !0, !1
          4      > JMPZ                                                     ~3, ->16
    5     5    >   NEW                                              $4      'Exception'
          6      > JMPZ                                                     !2, ->9
          7    >   QM_ASSIGN                                        ~5      !2
          8      > JMP                                                      ->12
          9    >   CONCAT                                           ~6      !1, '+did+not+equal+'
         10        CONCAT                                           ~7      ~6, !0
         11        QM_ASSIGN                                        ~5      ~7
         12    >   CONCAT                                           ~8      'Assertion%21+', ~5
         13        SEND_VAL_EX                                              ~8
         14        DO_FCALL                                      0          
         15      > THROW                                         0          $4
    7    16    > > RETURN                                                   null

End of function notequals

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
155.78 ms | 1013 KiB | 15 Q