3v4l.org

run code in 300+ PHP versions simultaneously
<?php $part = stristr('my home is my castle','is',true); $part2 = stristr('my home is my castle','is'); if($pos=stripos($h,$n)) $part3=substr($h,0,$pos); echo "This is my: $part\n"; echo "That is my: $part2\n"; echo "Also, this: $part3\n"; ?>
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 17, Position 2 = 23
Branch analysis from position: 17
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 23
filename:       /in/M1ZYZ
function name:  (null)
number of ops:  36
compiled vars:  !0 = $part, !1 = $part2, !2 = $pos, !3 = $h, !4 = $n, !5 = $part3
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL                                               'stristr'
          1        SEND_VAL                                                 'my+home+is+my+castle'
          2        SEND_VAL                                                 'is'
          3        SEND_VAL                                                 <true>
          4        DO_ICALL                                         $6      
          5        ASSIGN                                                   !0, $6
    3     6        INIT_FCALL                                               'stristr'
          7        SEND_VAL                                                 'my+home+is+my+castle'
          8        SEND_VAL                                                 'is'
          9        DO_ICALL                                         $8      
         10        ASSIGN                                                   !1, $8
    4    11        INIT_FCALL                                               'stripos'
         12        SEND_VAR                                                 !3
         13        SEND_VAR                                                 !4
         14        DO_ICALL                                         $10     
         15        ASSIGN                                           ~11     !2, $10
         16      > JMPZ                                                     ~11, ->23
         17    >   INIT_FCALL                                               'substr'
         18        SEND_VAR                                                 !3
         19        SEND_VAL                                                 0
         20        SEND_VAR                                                 !2
         21        DO_ICALL                                         $12     
         22        ASSIGN                                                   !5, $12
    5    23    >   ROPE_INIT                                     3  ~15     'This+is+my%3A+'
         24        ROPE_ADD                                      1  ~15     ~15, !0
         25        ROPE_END                                      2  ~14     ~15, '%0A'
         26        ECHO                                                     ~14
    6    27        ROPE_INIT                                     3  ~18     'That+is+my%3A+'
         28        ROPE_ADD                                      1  ~18     ~18, !1
         29        ROPE_END                                      2  ~17     ~18, '%0A'
         30        ECHO                                                     ~17
    7    31        ROPE_INIT                                     3  ~21     'Also%2C+this%3A+'
         32        ROPE_ADD                                      1  ~21     ~21, !5
         33        ROPE_END                                      2  ~20     ~21, '%0A'
         34        ECHO                                                     ~20
    8    35      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
149.62 ms | 1396 KiB | 19 Q