3v4l.org

run code in 500+ PHP versions simultaneously
<?php $s = 'MAy'; $p = 'MAy'; $t = strpos($s, $p) === 0 ? substr($s, strlen($p)) : $s; var_dump($t);
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 5, Position 2 = 9
Branch analysis from position: 5
1 jumps found. (Code = 42) Position 1 = 10
Branch analysis from position: 10
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 9
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/tdvDY
function name:  (null)
number of ops:  15
compiled vars:  !0 = $s, !1 = $p, !2 = $t
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                       !0, 'MAy'
    4     1        ASSIGN                                                       !1, 'MAy'
    5     2        FRAMELESS_ICALL_2                strpos              ~5      !0, !1
          3        IS_IDENTICAL                                                 ~5, 0
          4      > JMPZ                                                         ~6, ->9
          5    >   STRLEN                                               ~7      !1
          6        FRAMELESS_ICALL_2                substr              ~8      !0, ~7
          7        QM_ASSIGN                                            ~9      ~8
          8      > JMP                                                          ->10
          9    >   QM_ASSIGN                                            ~9      !0
         10    >   ASSIGN                                                       !2, ~9
    6    11        INIT_FCALL                                                   'var_dump'
         12        SEND_VAR                                                     !2
         13        DO_ICALL                                                     
         14      > RETURN                                                       1

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
160.91 ms | 2125 KiB | 14 Q