3v4l.org

run code in 300+ PHP versions simultaneously
<?php $x = 129; $y = 1; $m = microtime(true); $y = 1 << ceil(log($x, 2)); echo ($m - microtime(true)), "\n\r"; $y = 1; $m = microtime(true); while ($y < $x) { $y = $y <<1; } echo microtime(true) - $m;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 29
Branch analysis from position: 29
2 jumps found. (Code = 44) Position 1 = 31, Position 2 = 27
Branch analysis from position: 31
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 27
2 jumps found. (Code = 44) Position 1 = 31, Position 2 = 27
Branch analysis from position: 31
Branch analysis from position: 27
filename:       /in/d2knB
function name:  (null)
number of ops:  37
compiled vars:  !0 = $x, !1 = $y, !2 = $m
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, 129
    4     1        ASSIGN                                                   !1, 1
    5     2        INIT_FCALL                                               'microtime'
          3        SEND_VAL                                                 <true>
          4        DO_ICALL                                         $5      
          5        ASSIGN                                                   !2, $5
    6     6        INIT_FCALL                                               'ceil'
          7        INIT_FCALL                                               'log'
          8        SEND_VAR                                                 !0
          9        SEND_VAL                                                 2
         10        DO_ICALL                                         $7      
         11        SEND_VAR                                                 $7
         12        DO_ICALL                                         $8      
         13        SL                                               ~9      1, $8
         14        ASSIGN                                                   !1, ~9
    7    15        INIT_FCALL                                               'microtime'
         16        SEND_VAL                                                 <true>
         17        DO_ICALL                                         $11     
         18        SUB                                              ~12     !2, $11
         19        ECHO                                                     ~12
         20        ECHO                                                     '%0A%0D'
    9    21        ASSIGN                                                   !1, 1
   10    22        INIT_FCALL                                               'microtime'
         23        SEND_VAL                                                 <true>
         24        DO_ICALL                                         $14     
         25        ASSIGN                                                   !2, $14
   11    26      > JMP                                                      ->29
   12    27    >   SL                                               ~16     !1, 1
         28        ASSIGN                                                   !1, ~16
   11    29    >   IS_SMALLER                                               !1, !0
         30      > JMPNZ                                                    ~18, ->27
   14    31    >   INIT_FCALL                                               'microtime'
         32        SEND_VAL                                                 <true>
         33        DO_ICALL                                         $19     
         34        SUB                                              ~20     $19, !2
         35        ECHO                                                     ~20
         36      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
143.9 ms | 1396 KiB | 19 Q