3v4l.org

run code in 300+ PHP versions simultaneously
<?php error_reporting(E_ALL); $original_text = str_repeat("This is a test.\nThis is only a test.\nThis is not an important string.\n", 100); $fn = tempnam(sys_get_temp_dir(), "bbq"); $fh = fopen($fn, 'w+'); fwrite($fh, $original_text); rewind($fh); $filter = stream_filter_append($fh, 'string.toupper', STREAM_FILTER_READ, 6); while (!feof($fh)) { $data = fread($fh, 100); echo "\n:" . strlen($data); }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 43
Branch analysis from position: 43
2 jumps found. (Code = 44) Position 1 = 48, Position 2 = 35
Branch analysis from position: 48
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 35
2 jumps found. (Code = 44) Position 1 = 48, Position 2 = 35
Branch analysis from position: 48
Branch analysis from position: 35
filename:       /in/sVLAc
function name:  (null)
number of ops:  49
compiled vars:  !0 = $original_text, !1 = $fn, !2 = $fh, !3 = $filter, !4 = $data
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   INIT_FCALL                                               'error_reporting'
          1        SEND_VAL                                                 32767
          2        DO_ICALL                                                 
    5     3        INIT_FCALL                                               'str_repeat'
          4        SEND_VAL                                                 'This+is+a+test.%0AThis+is+only+a+test.%0AThis+is+not+an+important+string.%0A'
          5        SEND_VAL                                                 100
          6        DO_ICALL                                         $6      
          7        ASSIGN                                                   !0, $6
    6     8        INIT_FCALL                                               'tempnam'
          9        INIT_FCALL                                               'sys_get_temp_dir'
         10        DO_ICALL                                         $8      
         11        SEND_VAR                                                 $8
         12        SEND_VAL                                                 'bbq'
         13        DO_ICALL                                         $9      
         14        ASSIGN                                                   !1, $9
    7    15        INIT_FCALL                                               'fopen'
         16        SEND_VAR                                                 !1
         17        SEND_VAL                                                 'w%2B'
         18        DO_ICALL                                         $11     
         19        ASSIGN                                                   !2, $11
    8    20        INIT_FCALL                                               'fwrite'
         21        SEND_VAR                                                 !2
         22        SEND_VAR                                                 !0
         23        DO_ICALL                                                 
    9    24        INIT_FCALL                                               'rewind'
         25        SEND_VAR                                                 !2
         26        DO_ICALL                                                 
   11    27        INIT_FCALL                                               'stream_filter_append'
         28        SEND_VAR                                                 !2
         29        SEND_VAL                                                 'string.toupper'
         30        SEND_VAL                                                 1
         31        SEND_VAL                                                 6
         32        DO_ICALL                                         $15     
         33        ASSIGN                                                   !3, $15
   12    34      > JMP                                                      ->43
   13    35    >   INIT_FCALL                                               'fread'
         36        SEND_VAR                                                 !2
         37        SEND_VAL                                                 100
         38        DO_ICALL                                         $17     
         39        ASSIGN                                                   !4, $17
   14    40        STRLEN                                           ~19     !4
         41        CONCAT                                           ~20     '%0A%3A', ~19
         42        ECHO                                                     ~20
   12    43    >   INIT_FCALL                                               'feof'
         44        SEND_VAR                                                 !2
         45        DO_ICALL                                         $21     
         46        BOOL_NOT                                         ~22     $21
         47      > JMPNZ                                                    ~22, ->35
   15    48    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
155.34 ms | 1400 KiB | 33 Q