3v4l.org

run code in 300+ PHP versions simultaneously
<?php $start = microtime(true); $arr = []; for ($i = 0; $i < 1000; $i++) { array_push($arr, $i); } $end = microtime(true); echo number_format($end - $start, 8, '.', '') . "\n"; unset($arr); $start = microtime(true); $arr = []; for ($i = 0; $i < 1000; $i++) { $arr[] = $i; } $end = microtime(true); echo number_format($end - $start, 8, '.', '') . "\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)
7.4.10.0100.00715.00
7.4.00.0000.01615.09
7.3.130.0060.00614.85
7.3.120.0070.01315.01
7.3.110.0140.00414.85
7.3.100.0000.01515.12
7.3.90.0000.01714.77
7.3.80.0000.01515.01
7.3.70.0070.00714.75
7.3.60.0070.00814.95
7.3.50.0030.01014.91
7.3.40.0070.00714.86
7.3.30.0030.01314.91
7.3.20.0110.00316.37
7.3.10.0060.01016.73
7.3.00.0060.00916.84
7.2.260.0100.01015.32
7.2.250.0120.00615.02
7.2.240.0000.01815.06
7.2.230.0040.00815.18
7.2.220.0050.00515.02
7.2.210.0060.00915.17
7.2.200.0060.00615.11
7.2.190.0000.01315.20
7.2.180.0040.01114.92
7.2.170.0000.01515.00
7.2.160.0100.00315.08
7.2.150.0060.00917.07
7.2.140.0070.00317.05
7.2.130.0100.00317.00
7.2.120.0090.00616.91
7.2.110.0060.00916.85
7.2.100.0030.01416.82
7.2.90.0030.01016.86
7.2.80.0060.01117.06
7.2.70.0000.01416.72
7.2.60.0030.01016.99
7.2.50.0070.01116.94
7.2.40.0090.00616.63
7.2.30.0000.01516.96
7.2.20.0060.00916.84
7.2.10.0070.01016.93
7.2.00.0080.00817.97
7.1.330.0040.01115.65
7.1.320.0040.00815.71
7.1.310.0030.01415.75
7.1.300.0040.01115.82
7.1.290.0040.00815.52
7.1.280.0030.01015.53
7.1.270.0100.00715.99
7.1.260.0080.00015.98
7.1.250.0130.00315.82
7.1.240.0000.01215.79
7.1.230.0040.01115.55
7.1.220.0060.00615.95
7.1.210.0110.00016.00
7.1.200.0000.01515.87
7.1.190.0000.01015.97
7.1.180.0130.00315.79
7.1.170.0070.00815.55
7.1.160.0120.00315.92
7.1.150.0030.01215.97
7.1.140.0100.00715.80
7.1.130.0040.00815.91
7.1.120.0060.00615.80
7.1.110.0070.00715.75
7.1.100.0080.00415.95
7.1.90.0070.00715.69
7.1.80.0060.00615.84
7.1.70.0060.00416.54
7.1.60.0030.01016.63
7.1.50.0160.00825.13
7.1.40.0070.00715.95
7.1.30.0070.00715.55
7.1.20.0120.03827.09
7.1.10.0700.03818.00
7.1.00.0590.04118.19
7.0.330.0060.00615.36
7.0.320.0060.00615.46
7.0.310.0110.00315.33
7.0.300.0050.00315.44
7.0.290.0130.00015.45
7.0.280.0080.00515.23
7.0.270.0040.00415.22
7.0.260.0030.01015.60
7.0.250.0070.00715.32
7.0.240.0040.00715.61
7.0.230.0120.00315.34
7.0.220.0040.00415.48
7.0.210.0040.00715.44
7.0.200.0120.00316.05
7.0.190.0080.00415.64
7.0.180.0110.00415.55
7.0.170.0040.00715.21
7.0.160.0500.03217.64
7.0.150.0420.03617.79
7.0.140.0640.04417.77
7.0.130.0800.03917.84
7.0.120.0720.04417.96
7.0.110.0530.03817.81
7.0.100.0630.03017.77
7.0.90.0700.03717.73
7.0.80.0740.03117.71
7.0.70.0610.03317.73
7.0.60.0580.04017.56
7.0.50.0750.03017.85
7.0.40.0600.03916.81
7.0.30.0570.04016.93
7.0.20.0970.03316.77
7.0.10.0750.04216.75
7.0.00.0440.03616.86
5.6.400.0000.01514.53
5.6.390.0070.00714.61
5.6.380.0040.01114.92
5.6.370.0070.00714.78
5.6.360.0040.01114.27
5.6.350.0070.01014.51
5.6.340.0090.00614.23
5.6.330.0040.01114.53
5.6.320.0000.01014.71
5.6.310.0000.01414.67
5.6.300.0080.00314.11
5.6.290.0060.00914.78
5.6.280.0030.01214.82
5.6.270.0040.01114.54
5.6.260.0000.01714.64
5.6.250.0080.00514.48
5.6.240.0000.01614.41
5.6.230.0060.01014.57
5.6.220.0040.01114.48
5.6.210.0060.00914.46
5.6.200.0120.00314.47
5.6.190.0070.00714.66
5.6.180.0070.00714.64
5.6.170.0130.00314.41
5.6.160.0030.00914.28
5.6.150.0060.00914.34
5.6.140.0000.01814.43
5.6.130.0030.01314.34
5.6.120.0060.00914.41
5.6.110.0060.00814.40
5.6.100.0040.01214.44
5.6.90.0040.01114.37
5.6.80.0060.00614.62
5.6.70.0040.01114.38
5.6.60.0080.00314.56
5.6.50.0070.00714.53
5.6.40.0060.00914.46
5.6.30.0000.01114.52
5.6.20.0090.00314.67
5.6.10.0030.01014.52
5.6.00.0000.01414.39

preferences:
29.4 ms | 403 KiB | 5 Q