3v4l.org

run code in 300+ PHP versions simultaneously
<?php $str1 = 'football'; $str2 = 'footboll'; $strPos = strspn($str1 , $str2); echo $str1[$strPos].'vs'. $str2[$strPos]; ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/3Jft4
function name:  (null)
number of ops:  13
compiled vars:  !0 = $str1, !1 = $str2, !2 = $strPos
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, 'football'
    3     1        ASSIGN                                                   !1, 'footboll'
    4     2        INIT_FCALL                                               'strspn'
          3        SEND_VAR                                                 !0
          4        SEND_VAR                                                 !1
          5        DO_ICALL                                         $5      
          6        ASSIGN                                                   !2, $5
    5     7        FETCH_DIM_R                                      ~7      !0, !2
          8        CONCAT                                           ~8      ~7, 'vs'
          9        FETCH_DIM_R                                      ~9      !1, !2
         10        CONCAT                                           ~10     ~8, ~9
         11        ECHO                                                     ~10
    7    12      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
152.2 ms | 1394 KiB | 15 Q