3v4l.org

run code in 300+ PHP versions simultaneously
<?php function microtime_float() { list($usec, $sec) = explode(" ", microtime()); return ((float)$usec + (float)$sec); } $time_start = microtime_float(); var_dump($time); $time_end = microtime_float(); $time = round( ( $time_end - $time_start ) * 1000, 3 ); echo "time: $time ms\n";
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Tn9qN
function name:  (null)
number of ops:  21
compiled vars:  !0 = $time_start, !1 = $time, !2 = $time_end
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    9     0  E >   INIT_FCALL                                               'microtime_float'
          1        DO_FCALL                                      0  $3      
          2        ASSIGN                                                   !0, $3
   12     3        INIT_FCALL                                               'var_dump'
          4        SEND_VAR                                                 !1
          5        DO_ICALL                                                 
   15     6        INIT_FCALL                                               'microtime_float'
          7        DO_FCALL                                      0  $6      
          8        ASSIGN                                                   !2, $6
   16     9        INIT_FCALL                                               'round'
         10        SUB                                              ~8      !2, !0
         11        MUL                                              ~9      ~8, 1000
         12        SEND_VAL                                                 ~9
         13        SEND_VAL                                                 3
         14        DO_ICALL                                         $10     
         15        ASSIGN                                                   !1, $10
   18    16        ROPE_INIT                                     3  ~13     'time%3A+'
         17        ROPE_ADD                                      1  ~13     ~13, !1
         18        ROPE_END                                      2  ~12     ~13, '+ms%0A'
         19        ECHO                                                     ~12
         20      > RETURN                                                   1

Function microtime_float:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Tn9qN
function name:  microtime_float
number of ops:  16
compiled vars:  !0 = $usec, !1 = $sec
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   INIT_FCALL                                               'explode'
          1        SEND_VAL                                                 '+'
          2        INIT_FCALL                                               'microtime'
          3        DO_ICALL                                         $2      
          4        SEND_VAR                                                 $2
          5        DO_ICALL                                         $3      
          6        FETCH_LIST_R                                     $4      $3, 0
          7        ASSIGN                                                   !0, $4
          8        FETCH_LIST_R                                     $6      $3, 1
          9        ASSIGN                                                   !1, $6
         10        FREE                                                     $3
    6    11        CAST                                          5  ~8      !0
         12        CAST                                          5  ~9      !1
         13        ADD                                              ~10     ~8, ~9
         14      > RETURN                                                   ~10
    7    15*     > RETURN                                                   null

End of function microtime_float

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
152.34 ms | 1398 KiB | 23 Q