3v4l.org

run code in 300+ PHP versions simultaneously
<?php $string = 'Hello'; $stringLength = strlen($string); $bufferString = ''; for ($i = $stringLength - 1; $i > 0; $i--) { $bufferString .= $string[$i]; } echo $bufferString;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 10
Branch analysis from position: 10
2 jumps found. (Code = 44) Position 1 = 12, Position 2 = 7
Branch analysis from position: 12
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 7
2 jumps found. (Code = 44) Position 1 = 12, Position 2 = 7
Branch analysis from position: 12
Branch analysis from position: 7
filename:       /in/Bp0Xj
function name:  (null)
number of ops:  14
compiled vars:  !0 = $string, !1 = $stringLength, !2 = $bufferString, !3 = $i
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, 'Hello'
    4     1        STRLEN                                           ~5      !0
          2        ASSIGN                                                   !1, ~5
    5     3        ASSIGN                                                   !2, ''
    7     4        SUB                                              ~8      !1, 1
          5        ASSIGN                                                   !3, ~8
          6      > JMP                                                      ->10
    8     7    >   FETCH_DIM_R                                      ~10     !0, !3
          8        ASSIGN_OP                                     8          !2, ~10
    7     9        PRE_DEC                                                  !3
         10    >   IS_SMALLER                                               0, !3
         11      > JMPNZ                                                    ~13, ->7
   11    12    >   ECHO                                                     !2
         13      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
145.76 ms | 1393 KiB | 13 Q