3v4l.org

run code in 300+ PHP versions simultaneously
<?php var_dump(check('a', 'A')); var_dump(check('b', 'B')); var_dump(check('b', 'A')); var_dump(check('C', 'A')); var_dump(check('a', 'a')); function check($a, $b) { return strtoupper($b) === $a || $b === strtoupper($a); }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/rjBpS
function name:  (null)
number of ops:  36
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   INIT_FCALL                                               'var_dump'
          1        INIT_FCALL_BY_NAME                                       'check'
          2        SEND_VAL_EX                                              'a'
          3        SEND_VAL_EX                                              'A'
          4        DO_FCALL                                      0  $0      
          5        SEND_VAR                                                 $0
          6        DO_ICALL                                                 
    4     7        INIT_FCALL                                               'var_dump'
          8        INIT_FCALL_BY_NAME                                       'check'
          9        SEND_VAL_EX                                              'b'
         10        SEND_VAL_EX                                              'B'
         11        DO_FCALL                                      0  $2      
         12        SEND_VAR                                                 $2
         13        DO_ICALL                                                 
    5    14        INIT_FCALL                                               'var_dump'
         15        INIT_FCALL_BY_NAME                                       'check'
         16        SEND_VAL_EX                                              'b'
         17        SEND_VAL_EX                                              'A'
         18        DO_FCALL                                      0  $4      
         19        SEND_VAR                                                 $4
         20        DO_ICALL                                                 
    6    21        INIT_FCALL                                               'var_dump'
         22        INIT_FCALL_BY_NAME                                       'check'
         23        SEND_VAL_EX                                              'C'
         24        SEND_VAL_EX                                              'A'
         25        DO_FCALL                                      0  $6      
         26        SEND_VAR                                                 $6
         27        DO_ICALL                                                 
    7    28        INIT_FCALL                                               'var_dump'
         29        INIT_FCALL_BY_NAME                                       'check'
         30        SEND_VAL_EX                                              'a'
         31        SEND_VAL_EX                                              'a'
         32        DO_FCALL                                      0  $8      
         33        SEND_VAR                                                 $8
         34        DO_ICALL                                                 
   11    35      > RETURN                                                   1

Function check:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 47) Position 1 = 7, Position 2 = 12
Branch analysis from position: 7
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 12
filename:       /in/rjBpS
function name:  check
number of ops:  14
compiled vars:  !0 = $a, !1 = $b
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    9     0  E >   RECV                                             !0      
          1        RECV                                             !1      
   10     2        INIT_FCALL                                               'strtoupper'
          3        SEND_VAR                                                 !1
          4        DO_ICALL                                         $2      
          5        IS_IDENTICAL                                     ~3      !0, $2
          6      > JMPNZ_EX                                         ~3      ~3, ->12
          7    >   INIT_FCALL                                               'strtoupper'
          8        SEND_VAR                                                 !0
          9        DO_ICALL                                         $4      
         10        IS_IDENTICAL                                     ~5      !1, $4
         11        BOOL                                             ~3      ~5
         12    > > RETURN                                                   ~3
   11    13*     > RETURN                                                   null

End of function check

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
144.46 ms | 1400 KiB | 17 Q