3v4l.org

run code in 300+ PHP versions simultaneously
<?php $i=0; $j=500000; while($i < 60000) { $i++; $j+d+; $data1[] = md5($i); $data2[] = 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";

Here you find the average performance (time & memory) of each version. A grayed out version indicates it didn't complete successfully (based on exit-code).

VersionSystem time (s)User time (s)Memory (MiB)
5.4.160.0090.04312.36
5.4.150.0150.06112.35
5.4.140.0200.05612.04
5.4.130.0150.05812.02
5.4.120.0130.04111.99
5.4.110.0200.05311.98
5.4.100.0190.05811.98
5.4.90.0140.04911.98
5.4.80.0190.06011.98
5.4.70.0190.05211.98
5.4.60.0110.04111.98
5.4.50.0110.04111.98
5.4.40.0140.05811.97
5.4.30.0180.05611.96
5.4.20.0160.03811.96
5.4.10.0200.04111.96
5.4.00.0180.05811.46
5.3.260.0130.04012.72
5.3.250.0110.04312.72
5.3.240.0110.04312.72
5.3.230.0150.06012.71
5.3.220.0150.05012.68
5.3.210.0130.04712.68
5.3.200.0310.05312.68
5.3.190.0220.06612.68
5.3.180.0120.04412.67
5.3.170.0190.06412.67
5.3.160.0160.07212.67
5.3.150.0160.04212.67
5.3.140.0190.04812.66
5.3.130.0210.06112.66
5.3.120.0180.06212.66
5.3.110.0210.05812.66
5.3.100.0160.05112.12
5.3.90.0150.06012.08
5.3.80.0140.04612.08
5.3.70.0140.04412.08
5.3.60.0160.06112.06
5.3.50.0130.04412.00
5.3.40.0130.04512.00
5.3.30.0200.05711.94
5.3.20.0120.05911.71
5.3.10.0110.04011.67
5.3.00.0130.04111.65
5.2.170.0230.0489.16
5.2.160.0100.0339.16
5.2.150.0100.0389.16
5.2.140.0170.0609.16
5.2.130.0110.0369.12
5.2.120.0130.0549.12
5.2.110.0170.0469.12
5.2.100.0120.0309.12
5.2.90.0200.0449.12
5.2.80.0120.0349.11
5.2.70.0090.0369.11
5.2.60.0100.0369.07
5.2.50.0200.0589.04
5.2.40.0110.0379.01
5.2.30.0110.0348.98
5.2.20.0340.0418.98
5.2.10.0140.0498.90
5.2.00.0080.0358.76
5.1.60.0100.0278.05
5.1.50.0090.0298.05
5.1.40.0450.0398.04
5.1.30.0180.0268.37
5.1.20.0090.0328.41
5.1.10.0180.0468.13
5.1.00.0160.0428.13
5.0.50.0060.0266.60
5.0.40.0100.0466.46
5.0.30.0150.0676.28
5.0.20.0090.0236.25
5.0.10.0060.0266.23
5.0.00.0090.0356.22
4.4.90.0110.0384.78
4.4.80.0060.0214.75
4.4.70.0090.0354.75
4.4.60.0080.0204.75
4.4.50.0150.0304.77
4.4.40.0060.0494.71
4.4.30.0070.0174.76
4.4.20.0060.0174.84
4.4.10.0050.0194.85
4.4.00.0090.0454.76
4.3.110.0060.0184.67
4.3.100.0060.0164.67
4.3.90.0050.0174.63
4.3.80.0120.0404.58
4.3.70.0040.0184.63
4.3.60.0060.0164.62
4.3.50.0050.0184.63
4.3.40.0060.0274.54
4.3.30.0050.0173.29
4.3.20.0040.0173.28
4.3.10.0050.0173.24
4.3.00.0130.0176.89

preferences:
138.03 ms | 1394 KiB | 7 Q