3v4l.org

run code in 300+ PHP versions simultaneously
<?php $filter = "cmt test test test"; if (substr($filter, 0,3) == 'cmt') { echo hi; }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 8, Position 2 = 10
Branch analysis from position: 8
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 10
filename:       /in/A3m0Q
function name:  (null)
number of ops:  11
compiled vars:  !0 = $filter
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, 'cmt+test+test+test'
    3     1        INIT_FCALL                                               'substr'
          2        SEND_VAR                                                 !0
          3        SEND_VAL                                                 0
          4        SEND_VAL                                                 3
          5        DO_ICALL                                         $2      
          6        IS_EQUAL                                                 $2, 'cmt'
          7      > JMPZ                                                     ~3, ->10
          8    >   FETCH_CONSTANT                                   ~4      'hi'
          9        ECHO                                                     ~4
         10    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
141.52 ms | 1398 KiB | 15 Q