3v4l.org

run code in 300+ PHP versions simultaneously
<?php $start = microtime(true); for ($i = 0; $i < 10000; $i++) { array_map('strip_tags', range(0, $i)); } echo microtime(true) - $start, PHP_EOL; $start = microtime(true); for ($i = 0; $i < 10000; $i++) { array_map(function ($i) { return strip_tags($i); }, range(0, $i)); } echo microtime(true) - $start, PHP_EOL;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 15
Branch analysis from position: 15
2 jumps found. (Code = 44) Position 1 = 17, Position 2 = 6
Branch analysis from position: 17
1 jumps found. (Code = 42) Position 1 = 39
Branch analysis from position: 39
2 jumps found. (Code = 44) Position 1 = 41, Position 2 = 29
Branch analysis from position: 41
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 29
2 jumps found. (Code = 44) Position 1 = 41, Position 2 = 29
Branch analysis from position: 41
Branch analysis from position: 29
Branch analysis from position: 6
2 jumps found. (Code = 44) Position 1 = 17, Position 2 = 6
Branch analysis from position: 17
Branch analysis from position: 6
filename:       /in/GVsa3
function name:  (null)
number of ops:  48
compiled vars:  !0 = $start, !1 = $i
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   INIT_FCALL                                               'microtime'
          1        SEND_VAL                                                 <true>
          2        DO_ICALL                                         $2      
          3        ASSIGN                                                   !0, $2
    5     4        ASSIGN                                                   !1, 0
          5      > JMP                                                      ->15
    6     6    >   INIT_FCALL                                               'array_map'
          7        SEND_VAL                                                 'strip_tags'
          8        INIT_FCALL                                               'range'
          9        SEND_VAL                                                 0
         10        SEND_VAR                                                 !1
         11        DO_ICALL                                         $5      
         12        SEND_VAR                                                 $5
         13        DO_ICALL                                                 
    5    14        PRE_INC                                                  !1
         15    >   IS_SMALLER                                               !1, 10000
         16      > JMPNZ                                                    ~8, ->6
    9    17    >   INIT_FCALL                                               'microtime'
         18        SEND_VAL                                                 <true>
         19        DO_ICALL                                         $9      
         20        SUB                                              ~10     $9, !0
         21        ECHO                                                     ~10
         22        ECHO                                                     '%0A'
   12    23        INIT_FCALL                                               'microtime'
         24        SEND_VAL                                                 <true>
         25        DO_ICALL                                         $11     
         26        ASSIGN                                                   !0, $11
   14    27        ASSIGN                                                   !1, 0
         28      > JMP                                                      ->39
   15    29    >   INIT_FCALL                                               'array_map'
         30        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2FGVsa3%3A15%240'
         31        SEND_VAL                                                 ~14
         32        INIT_FCALL                                               'range'
         33        SEND_VAL                                                 0
         34        SEND_VAR                                                 !1
         35        DO_ICALL                                         $15     
         36        SEND_VAR                                                 $15
         37        DO_ICALL                                                 
   14    38        PRE_INC                                                  !1
         39    >   IS_SMALLER                                               !1, 10000
         40      > JMPNZ                                                    ~18, ->29
   18    41    >   INIT_FCALL                                               'microtime'
         42        SEND_VAL                                                 <true>
         43        DO_ICALL                                         $19     
         44        SUB                                              ~20     $19, !0
         45        ECHO                                                     ~20
         46        ECHO                                                     '%0A'
         47      > RETURN                                                   1

Function %00%7Bclosure%7D%2Fin%2FGVsa3%3A15%240:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/GVsa3
function name:  {closure}
number of ops:  6
compiled vars:  !0 = $i
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   15     0  E >   RECV                                             !0      
          1        INIT_FCALL                                               'strip_tags'
          2        SEND_VAR                                                 !0
          3        DO_ICALL                                         $1      
          4      > RETURN                                                   $1
          5*     > RETURN                                                   null

End of function %00%7Bclosure%7D%2Fin%2FGVsa3%3A15%240

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
155.72 ms | 1405 KiB | 21 Q