3v4l.org

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

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
148.49 ms | 1400 KiB | 21 Q