3v4l.org

run code in 300+ PHP versions simultaneously
<?php $max = 32767; $n = 20; $step = intval($max/$n); for ($i=0; $i<=$n; $i++) { $val = $i*$step; echo base64_encode(pack('N', $val)) . " $val \n"; }
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 22
Branch analysis from position: 22
2 jumps found. (Code = 44) Position 1 = 24, Position 2 = 7
Branch analysis from position: 24
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 7
2 jumps found. (Code = 44) Position 1 = 24, Position 2 = 7
Branch analysis from position: 24
Branch analysis from position: 7
filename:       /in/sbj0D
function name:  (null)
number of ops:  25
compiled vars:  !0 = $max, !1 = $n, !2 = $step, !3 = $i, !4 = $val
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, 32767
    4     1        ASSIGN                                                   !1, 20
    5     2        DIV                                              ~7      !0, !1
          3        CAST                                          4  ~8      ~7
          4        ASSIGN                                                   !2, ~8
    7     5        ASSIGN                                                   !3, 0
          6      > JMP                                                      ->22
    8     7    >   MUL                                              ~11     !3, !2
          8        ASSIGN                                                   !4, ~11
    9     9        INIT_FCALL                                               'base64_encode'
         10        INIT_FCALL                                               'pack'
         11        SEND_VAL                                                 'N'
         12        SEND_VAR                                                 !4
         13        DO_ICALL                                         $13     
         14        SEND_VAR                                                 $13
         15        DO_ICALL                                         $14     
         16        ROPE_INIT                                     3  ~16     '+'
         17        ROPE_ADD                                      1  ~16     ~16, !4
         18        ROPE_END                                      2  ~15     ~16, '+%0A'
         19        CONCAT                                           ~18     $14, ~15
         20        ECHO                                                     ~18
    7    21        PRE_INC                                                  !3
         22    >   IS_SMALLER_OR_EQUAL                                      !3, !1
         23      > JMPNZ                                                    ~20, ->7
   10    24    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
152.4 ms | 1399 KiB | 17 Q