3v4l.org

run code in 300+ PHP versions simultaneously
<?php if(substr($str, 0, 3) == pack("CCC", 0xef, 0xbb, 0xbf)) { $str = substr($str, 3); }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 13, Position 2 = 18
Branch analysis from position: 13
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 18
filename:       /in/gIgq5
function name:  (null)
number of ops:  19
compiled vars:  !0 = $str
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   INIT_FCALL                                               'substr'
          1        SEND_VAR                                                 !0
          2        SEND_VAL                                                 0
          3        SEND_VAL                                                 3
          4        DO_ICALL                                         $1      
          5        INIT_FCALL                                               'pack'
          6        SEND_VAL                                                 'CCC'
          7        SEND_VAL                                                 239
          8        SEND_VAL                                                 187
          9        SEND_VAL                                                 191
         10        DO_ICALL                                         $2      
         11        IS_EQUAL                                                 $1, $2
         12      > JMPZ                                                     ~3, ->18
    5    13    >   INIT_FCALL                                               'substr'
         14        SEND_VAR                                                 !0
         15        SEND_VAL                                                 3
         16        DO_ICALL                                         $4      
         17        ASSIGN                                                   !0, $4
    6    18    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
156.99 ms | 1394 KiB | 17 Q