3v4l.org

run code in 300+ PHP versions simultaneously
<?php $var='abcdefghi'; $start = microtime(true); for($x = 0; $x < 1000; $x++){ if($var == 'abcdefghi'){} } $end = microtime(true); $elapsed = $end - $start; echo $elapsed, " seconds .";
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 = 43) Position 1 = 9, Position 2 = 9
Branch analysis from position: 9
2 jumps found. (Code = 44) Position 1 = 12, Position 2 = 7
Branch analysis from position: 12
Branch analysis from position: 7
Branch analysis from position: 9
filename:       /in/3ZfjQ
function name:  (null)
number of ops:  21
compiled vars:  !0 = $var, !1 = $start, !2 = $x, !3 = $end, !4 = $elapsed
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, 'abcdefghi'
    4     1        INIT_FCALL                                               'microtime'
          2        SEND_VAL                                                 <true>
          3        DO_ICALL                                         $6      
          4        ASSIGN                                                   !1, $6
    5     5        ASSIGN                                                   !2, 0
          6      > JMP                                                      ->10
    6     7    >   IS_EQUAL                                                 !0, 'abcdefghi'
          8      > JMPZ                                                     ~9, ->9
    5     9    >   PRE_INC                                                  !2
         10    >   IS_SMALLER                                               !2, 1000
         11      > JMPNZ                                                    ~11, ->7
    8    12    >   INIT_FCALL                                               'microtime'
         13        SEND_VAL                                                 <true>
         14        DO_ICALL                                         $12     
         15        ASSIGN                                                   !3, $12
    9    16        SUB                                              ~14     !3, !1
         17        ASSIGN                                                   !4, ~14
   10    18        ECHO                                                     !4
         19        ECHO                                                     '+seconds+.'
         20      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
132.56 ms | 1400 KiB | 15 Q