3v4l.org

run code in 300+ PHP versions simultaneously
<?php $time = microtime(true); $i=0; while($i < 60000) { $i++; $data[] = substr('../sites/swissquote.eu.fx', strrpos('../sites/swissquote.eu.fx', '/')+1); } $time = microtime(true) - $time; echo 'substr() took ' . number_format($time, 3) . ' seconds and returned ' . count($data) . " entries\n";
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 18
Branch analysis from position: 18
2 jumps found. (Code = 44) Position 1 = 20, Position 2 = 6
Branch analysis from position: 20
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 6
2 jumps found. (Code = 44) Position 1 = 20, Position 2 = 6
Branch analysis from position: 20
Branch analysis from position: 6
filename:       /in/nA6Mo
function name:  (null)
number of ops:  36
compiled vars:  !0 = $time, !1 = $i, !2 = $data
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   INIT_FCALL                                               'microtime'
          1        SEND_VAL                                                 <true>
          2        DO_ICALL                                         $3      
          3        ASSIGN                                                   !0, $3
    5     4        ASSIGN                                                   !1, 0
    6     5      > JMP                                                      ->18
    7     6    >   PRE_INC                                                  !1
    8     7        INIT_FCALL                                               'substr'
          8        SEND_VAL                                                 '..%2Fsites%2Fswissquote.eu.fx'
          9        INIT_FCALL                                               'strrpos'
         10        SEND_VAL                                                 '..%2Fsites%2Fswissquote.eu.fx'
         11        SEND_VAL                                                 '%2F'
         12        DO_ICALL                                         $8      
         13        ADD                                              ~9      $8, 1
         14        SEND_VAL                                                 ~9
         15        DO_ICALL                                         $10     
         16        ASSIGN_DIM                                               !2
         17        OP_DATA                                                  $10
    6    18    >   IS_SMALLER                                               !1, 60000
         19      > JMPNZ                                                    ~11, ->6
   11    20    >   INIT_FCALL                                               'microtime'
         21        SEND_VAL                                                 <true>
         22        DO_ICALL                                         $12     
         23        SUB                                              ~13     $12, !0
         24        ASSIGN                                                   !0, ~13
   13    25        INIT_FCALL                                               'number_format'
         26        SEND_VAR                                                 !0
         27        SEND_VAL                                                 3
         28        DO_ICALL                                         $15     
         29        CONCAT                                           ~16     'substr%28%29+took+', $15
         30        CONCAT                                           ~17     ~16, '+seconds+and+returned+'
         31        COUNT                                            ~18     !2
         32        CONCAT                                           ~19     ~17, ~18
         33        CONCAT                                           ~20     ~19, '+entries%0A'
         34        ECHO                                                     ~20
         35      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
148.01 ms | 1401 KiB | 21 Q