3v4l.org

run code in 300+ PHP versions simultaneously
<?php $n = 10000; $a = new SplFixedArray($n); for($i = 0; $i < $n; $i++) $a[$i] = range(1,RAND(100,1000)); print count($a);

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.0420.02359.39
7.4.00.0270.03359.47
7.3.130.0300.03059.36
7.3.120.0270.02059.90
7.3.110.0400.02659.57
7.3.100.0230.02059.68
7.3.90.0240.02059.07
7.3.80.0270.02059.80
7.3.70.0140.02159.57
7.3.60.0270.01359.14
7.3.50.0350.01059.52
7.3.40.0320.01159.73
7.3.30.0200.02059.54
7.3.20.0170.02478.43
7.3.10.0460.02278.52
7.3.00.0610.02078.38
7.2.260.0440.02059.74
7.2.250.0400.02359.90
7.2.240.0100.02859.49
7.2.230.0330.01359.89
7.2.220.0360.00359.82
7.2.210.0230.02059.86
7.2.200.0190.01959.33
7.2.190.0170.02359.12
7.2.180.0200.02760.05
7.2.170.0200.02059.81
7.2.160.0300.01359.66
7.2.150.0300.01778.98
7.2.140.0160.02078.85
7.2.130.0790.01778.54
7.2.120.1210.01478.55
7.2.110.1240.01978.76
7.2.100.1160.02378.60
7.2.90.1200.02178.67
7.2.80.1240.01678.78
7.2.70.0860.01878.81
7.2.60.0830.01878.80
7.2.50.1380.02678.74
7.2.40.0690.02178.82
7.2.30.1060.02478.81
7.2.20.0470.01878.72
7.2.10.1210.01878.68
7.2.00.1880.02778.86
7.1.330.0120.01877.77
7.1.320.0100.02377.89
7.1.310.0180.01177.84
7.1.300.0230.01077.98
7.1.290.0200.02077.80
7.1.280.0130.01777.73
7.1.270.0220.02277.46
7.1.260.0130.02277.51
7.1.250.1040.01377.35
7.1.240.0100.02877.79
7.1.230.0100.03777.72
7.1.220.0160.03277.83
7.1.210.0070.02777.89
7.1.200.0220.01277.82
7.1.190.0190.01577.46
7.1.180.0210.01477.43
7.1.170.0170.02777.67
7.1.160.0140.02477.70
7.1.150.0110.01877.88
7.1.140.0100.02677.87
7.1.130.0200.02077.70
7.1.120.0160.01677.75
7.1.110.0070.02377.94
7.1.100.0060.02277.94
7.1.90.0170.01777.71
7.1.80.0140.02177.77
7.1.70.0150.02078.29
7.1.60.0210.02378.53
7.1.50.0290.02278.43
7.1.40.0030.02677.63
7.1.30.0200.01377.53
7.1.20.0130.02077.83
7.1.10.0190.02577.89
7.1.00.0130.05381.02
7.0.330.0160.01777.51
7.0.320.0100.01677.38
7.0.310.0170.01777.46
7.0.300.0200.01377.22
7.0.290.0060.02377.31
7.0.280.0130.01677.36
7.0.270.0100.02377.46
7.0.260.0090.01977.50
7.0.250.0100.02177.50
7.0.240.0130.02277.58
7.0.230.0200.01677.68
7.0.220.0100.01777.41
7.0.210.0190.00977.41
7.0.200.2770.01976.25
7.0.190.0100.02177.56
7.0.180.0130.02077.68
7.0.170.0170.02077.31
7.0.160.0100.02477.41
7.0.150.0170.01777.54
7.0.140.0100.05580.66
7.0.130.0240.02077.40
7.0.120.0100.02177.15
7.0.110.0070.02477.28
7.0.100.0580.04571.12
7.0.90.4400.03371.11
7.0.80.4150.05571.27
7.0.70.1320.04371.15
7.0.60.1350.03971.07
7.0.50.1860.04371.38
7.0.40.0180.03016.85
7.0.30.0070.04016.90
7.0.20.0050.03816.74
7.0.10.0120.04016.86
7.0.00.0160.04416.74
5.6.400.0430.04679.44
5.6.390.0440.06879.19
5.6.380.0300.07079.34
5.6.370.0200.08579.11
5.6.360.0490.04979.21
5.6.350.0330.06079.18
5.6.340.0470.06078.77
5.6.330.0370.07179.06
5.6.320.0270.06579.27
5.6.310.0500.04778.93
5.6.300.0360.07579.22
5.6.290.0360.07379.04
5.6.280.0280.09782.28
5.6.270.0260.07579.07
5.6.260.0500.05779.05
5.6.250.0330.09882.26
5.6.240.0330.10082.28
5.6.230.0270.11682.12
5.6.220.0260.07982.16
5.6.210.0230.07582.15
5.6.200.0180.07482.24
5.6.190.0210.07682.35
5.6.180.0430.07382.36
5.6.170.0300.07482.40
5.6.160.0180.08182.43
5.6.150.0350.08582.46
5.6.140.0420.11082.27
5.6.130.0400.08582.32
5.6.120.0330.09482.52
5.6.110.0360.09682.36
5.6.100.0430.09682.45
5.6.90.0270.09582.40
5.6.80.0260.09682.14
5.6.70.0320.09082.09
5.6.60.0280.09982.10
5.6.50.0320.09282.13
5.6.40.0300.09281.97
5.6.30.0300.11782.00
5.6.20.0480.09282.07
5.6.10.0400.08081.96
5.6.00.0300.10382.09
5.5.380.0300.10181.90
5.5.370.0320.08082.11
5.5.360.0390.06282.17
5.5.350.0230.07282.20
5.5.340.0300.07382.20
5.5.330.0350.06582.37
5.5.320.0200.08182.15
5.5.310.0280.07082.40
5.5.300.0250.10482.33
5.5.290.0350.09882.20
5.5.280.0380.09082.30
5.5.270.0420.09582.29
5.5.260.0310.11082.38
5.5.250.0420.08282.29
5.5.240.0300.09582.07
5.5.230.0250.11681.97
5.5.220.0400.08781.91
5.5.210.0350.09381.93
5.5.200.0320.10582.03
5.5.190.0370.09281.89
5.5.180.0330.09281.89
5.5.170.0200.07479.05
5.5.160.0450.08781.95
5.5.150.0430.09181.93
5.5.140.0420.10081.96
5.5.130.0370.08682.03
5.5.120.0400.06181.84
5.5.110.0320.09781.99
5.5.100.0300.08281.79
5.5.90.0430.10681.84
5.5.80.0320.08781.93
5.5.70.0390.07981.79
5.5.60.0450.09281.85
5.5.50.0200.09281.91
5.5.40.0380.09081.82
5.5.30.0330.09781.93
5.5.20.0420.12481.75
5.5.10.0350.10281.89
5.5.00.0250.07981.86
5.4.450.0390.08479.81
5.4.440.0360.09479.77
5.4.430.0280.10679.71
5.4.420.0370.09479.81
5.4.410.0260.10179.74
5.4.400.0220.10479.55
5.4.390.0430.08479.42
5.4.380.0350.09879.63
5.4.370.0350.09479.68
5.4.360.0280.09979.45
5.4.350.0350.08979.60
5.4.340.0350.10579.79
5.4.330.0260.07375.73
5.4.320.0150.10279.59
5.4.310.0480.09079.64
5.4.300.0270.09079.38
5.4.290.0330.09179.49
5.4.280.0300.09079.67
5.4.270.0270.10079.47
5.4.260.0280.09679.61
5.4.250.0350.08979.61
5.4.240.0280.09279.60
5.4.230.0230.10879.63
5.4.220.0250.09579.67
5.4.210.0200.10579.66
5.4.200.0350.07579.68
5.4.190.0270.10579.58
5.4.180.0380.09579.54
5.4.170.0400.08579.61
5.4.160.0280.08179.56
5.4.150.0210.09079.55
5.4.140.0280.08878.31
5.4.130.0280.09078.25
5.4.120.0280.09278.30
5.4.110.0300.08878.20
5.4.100.0200.09878.25
5.4.90.0360.09678.39
5.4.80.0320.10278.29
5.4.70.0270.09178.22
5.4.60.0350.08678.24
5.4.50.0200.10178.37
5.4.40.0350.08878.20
5.4.30.0350.09278.34
5.4.20.0270.08878.22
5.4.10.0380.07978.35
5.4.00.0320.09278.04
5.3.290.0220.11375.80
5.3.280.0290.08775.72
5.3.270.0360.09475.80
5.3.260.0250.10675.77
5.3.250.0320.09575.80
5.3.240.0270.11075.64
5.3.230.0230.10375.62
5.3.220.0320.10775.57
5.3.210.0230.11375.67
5.3.200.0380.08475.72
5.3.190.0280.09675.69
5.3.180.0300.07175.74
5.3.170.0280.10475.60
5.3.160.0370.10075.72
5.3.150.0200.11075.75
5.3.140.0360.08875.67
5.3.130.0300.07075.69
5.3.120.0280.09675.82
5.3.110.0100.09375.67
5.3.100.0300.08575.46
5.3.90.0260.10175.56
5.3.80.0370.09775.42
5.3.70.0430.09675.44
5.3.60.0280.09475.33
5.3.50.0310.09875.30
5.3.40.0300.10275.74
5.3.30.0380.09275.30
5.3.20.0380.10075.20
5.3.10.0250.10575.00
5.3.00.0260.08774.94
5.2.170.0000.04311.13
5.2.160.0100.04711.22
5.2.150.0030.07010.99
5.2.140.0000.06310.96
5.2.130.0070.06011.09
5.2.120.0000.05311.09
5.2.110.0070.05711.12
5.2.100.0000.06011.09
5.2.90.0030.05710.93
5.2.80.0070.06011.05
5.2.70.0100.05710.95
5.2.60.0070.06010.93
5.2.50.0030.05311.06
5.2.40.0070.05710.93
5.2.30.0070.06010.93
5.2.20.0070.06010.98
5.2.10.0030.06010.93
5.2.00.0100.05310.93
5.1.60.0070.04710.93
5.1.50.0000.06010.93
5.1.40.0030.05310.93
5.1.30.0030.06010.93
5.1.20.0000.06010.93
5.1.10.0030.05710.93
5.1.00.0100.05010.93
5.0.50.0100.04010.93
5.0.40.0030.04710.93
5.0.30.0000.05710.93
5.0.20.0070.04010.93
5.0.10.0000.03710.93
5.0.00.0070.05710.93
4.4.90.0030.03310.93
4.4.80.0030.03710.93
4.4.70.0000.04010.93
4.4.60.0000.03710.93
4.4.50.0000.03310.93
4.4.40.0000.05010.93
4.4.30.0070.03010.93
4.4.20.0070.03310.93
4.4.10.0000.02310.93
4.4.00.0000.05710.93
4.3.110.0000.03710.93
4.3.100.0000.03310.93
4.3.90.0030.03010.93
4.3.80.0000.05010.93
4.3.70.0000.02010.93
4.3.60.0030.03310.93
4.3.50.0070.03010.93
4.3.40.0030.05010.93
4.3.30.0000.02010.93
4.3.20.0000.02010.93
4.3.10.0000.04010.93
4.3.00.0030.03010.93

preferences:
35.35 ms | 401 KiB | 5 Q