3v4l.org

run code in 300+ PHP versions simultaneously
<?php $name = "<\? echo 'ool';"; if (preg_match("#<\?#", $name)) { print_r('ko'); } else { print_r('ok'); }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 6, Position 2 = 10
Branch analysis from position: 6
1 jumps found. (Code = 42) Position 1 = 13
Branch analysis from position: 13
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 10
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/4Bok9
function name:  (null)
number of ops:  14
compiled vars:  !0 = $name
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, '%3C%5C%3F+echo+%27ool%27%3B'
    5     1        INIT_FCALL                                               'preg_match'
          2        SEND_VAL                                                 '%23%3C%5C%3F%23'
          3        SEND_VAR                                                 !0
          4        DO_ICALL                                         $2      
          5      > JMPZ                                                     $2, ->10
    6     6    >   INIT_FCALL                                               'print_r'
          7        SEND_VAL                                                 'ko'
          8        DO_ICALL                                                 
          9      > JMP                                                      ->13
    9    10    >   INIT_FCALL                                               'print_r'
         11        SEND_VAL                                                 'ok'
         12        DO_ICALL                                                 
   10    13    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
160.92 ms | 1394 KiB | 17 Q