3v4l.org

run code in 300+ PHP versions simultaneously
<?php $pattern = '/HTTP/'; $serverProtocol = 'HTTP/1.1'; $protocol = preg_match($pattern, $serverProtocol, $matches); print_r($protocol, true);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/foj0S
function name:  (null)
number of ops:  13
compiled vars:  !0 = $pattern, !1 = $serverProtocol, !2 = $protocol, !3 = $matches
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, '%2FHTTP%2F'
    4     1        ASSIGN                                                   !1, 'HTTP%2F1.1'
    7     2        INIT_FCALL                                               'preg_match'
          3        SEND_VAR                                                 !0
          4        SEND_VAR                                                 !1
          5        SEND_REF                                                 !3
          6        DO_ICALL                                         $6      
          7        ASSIGN                                                   !2, $6
    9     8        INIT_FCALL                                               'print_r'
          9        SEND_VAR                                                 !2
         10        SEND_VAL                                                 <true>
         11        DO_ICALL                                                 
         12      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
175.07 ms | 1394 KiB | 17 Q