3v4l.org

run code in 300+ PHP versions simultaneously
<?php function foo() { $foo = array(); for($x = 0; $x < 100000; $x++){ $foo[] = pow($x,$x); } return $foo; } $t = microtime(true); foreach(foo() as $val){ $val = $val + 2; } echo round(microtime(true) - $t, 5)."\n"; $t = microtime(true); $foo = foo(); foreach($foo as $val){ $val = $val + 2; } echo round(microtime(true) - $t, 5)."\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.00.0130.04919.99
7.3.120.0200.04620.17
7.3.110.0170.04819.80
7.3.100.0160.02620.06
7.3.90.0070.05519.81
7.3.80.0100.03420.04
7.3.70.0160.02619.77
7.3.60.0100.03519.64
7.3.50.0000.04219.87
7.3.40.0070.03519.90
7.3.30.0000.03819.86
7.3.20.0190.02222.89
7.3.10.0210.03122.63
7.3.00.0180.03322.75
7.2.250.0130.05320.09
7.2.240.0070.06120.43
7.2.230.0070.04720.29
7.2.220.0230.04219.95
7.2.210.0130.05120.04
7.2.200.0130.03320.18
7.2.190.0160.04220.31
7.2.180.0070.03620.09
7.2.170.0070.03320.20
7.2.160.0130.03220.16
7.2.150.0160.02322.90
7.2.140.0100.02923.20
7.2.130.0150.03823.01
7.2.120.0220.03023.08
7.2.110.0290.03022.79
7.2.100.0290.02923.01
7.2.90.0200.03822.96
7.2.80.0280.03423.12
7.2.70.0230.03122.96
7.2.60.0280.02922.96
7.2.50.0300.03323.30
7.2.40.0310.03323.08
7.2.30.0310.02923.09
7.2.20.0160.03722.97
7.2.10.0240.03123.00
7.2.00.0170.03324.02
7.1.330.0100.05522.16
7.1.320.0030.07221.98
7.1.310.0100.06021.73
7.1.300.0030.07122.04
7.1.290.0100.05921.90
7.1.280.0030.07222.12
7.1.270.0030.06722.00
7.1.260.0130.05921.95
7.1.250.0140.06621.90
7.1.70.0030.03323.50
7.1.60.0170.07023.59
7.1.50.0030.07423.13
7.1.00.0000.06328.68
7.0.200.1800.04620.85
7.0.140.0070.11728.40
7.0.120.0070.11728.30
7.0.110.3330.10325.16
7.0.100.0930.10325.11
7.0.90.0570.06325.20
7.0.80.1230.10025.06
7.0.70.1030.10025.19
7.0.60.0670.06325.24
7.0.50.0670.06325.41
7.0.40.0630.06724.36
7.0.30.0270.08024.36
7.0.20.0570.07724.27
7.0.10.1930.11324.27
7.0.00.2300.10324.36
5.6.280.0100.17035.42
5.6.260.0130.15035.00
5.6.250.0170.16334.88
5.6.240.0100.14334.98
5.6.230.0200.15734.97
5.6.220.0130.10334.96
5.6.210.0070.11734.98
5.6.200.0130.11335.41
5.6.190.0100.14335.30
5.6.180.0070.11035.42
5.6.170.0130.10335.28
5.6.160.0100.15735.57
5.6.150.0230.13735.50
5.6.140.0170.16035.39
5.6.130.0270.14035.48
5.6.120.0270.15335.55
5.6.110.0200.14035.54
5.6.100.0230.14335.56
5.6.90.0100.14735.41
5.6.80.0300.14334.88
5.6.70.0230.16034.65
5.6.60.0100.17334.64
5.6.50.0230.15734.88
5.6.40.0370.13334.84
5.6.30.0130.14034.85
5.6.20.0100.16034.80
5.6.10.0200.16334.64
5.6.00.0100.15334.81
5.5.380.0100.10734.88
5.5.370.0270.15034.86
5.5.360.0100.13734.73
5.5.350.0100.12334.66
5.5.340.0100.18335.15
5.5.330.0130.10335.19
5.5.320.0300.08735.30
5.5.310.0100.15035.16
5.5.300.0200.15735.10
5.5.290.0100.18035.27
5.5.280.0130.15335.18
5.5.270.0200.17735.14
5.5.260.0230.15335.14
5.5.250.0100.15035.00
5.5.240.0000.16334.68
5.5.230.0130.15734.63
5.5.220.0200.16034.53
5.5.210.0130.16034.62
5.5.200.0200.15334.54
5.5.190.0200.16334.40
5.5.180.0130.15034.43
5.5.160.0130.16034.64
5.5.150.0230.14334.50
5.5.140.0300.13034.64
5.5.130.0100.20734.66
5.5.120.0200.14034.52
5.5.110.0130.16334.49
5.5.100.0170.15734.45
5.5.90.0270.14334.60
5.5.80.0270.15034.41
5.5.70.0230.13734.41
5.5.60.0230.15334.38
5.5.50.0130.15034.38
5.5.40.0070.17734.52
5.5.30.0100.16034.37
5.5.20.0130.17734.52
5.5.10.0230.16334.39
5.5.00.0170.15034.50
5.4.450.0200.12733.61
5.4.440.0170.15333.55
5.4.430.0030.15333.61
5.4.420.0100.16333.54
5.4.410.0070.16733.67
5.4.400.0370.12733.36
5.4.390.0100.17033.51
5.4.380.0300.14733.29
5.4.370.0170.14333.47
5.4.360.0130.14033.27
5.4.350.0130.15333.26
5.4.340.0170.17033.48
5.4.320.0030.15733.22
5.4.310.0100.16333.28
5.4.300.0170.12333.38
5.4.290.0270.15033.56
5.4.280.0170.15733.25
5.4.270.0130.16033.37
5.4.260.0230.14333.38
5.4.250.0100.15733.28
5.4.240.0200.16033.27
5.4.230.0100.18333.19
5.4.220.0230.13733.13
5.4.210.0300.13333.46
5.4.200.0200.15033.35
5.4.190.0170.14733.27
5.4.180.0270.14733.30
5.4.170.0100.15733.46
5.4.160.0230.14733.27
5.4.150.0200.15333.13
5.4.140.0230.14730.74
5.4.130.0370.12030.64
5.4.120.0130.15030.65
5.4.110.0230.14730.66
5.4.100.0200.12330.80
5.4.90.0230.14330.63
5.4.80.0100.16030.81
5.4.70.0200.13730.66
5.4.60.0030.13030.71
5.4.50.0200.15030.82
5.4.40.0070.16030.79
5.4.30.0230.13730.80
5.4.20.0330.13730.64
5.4.10.0130.14730.73
5.4.00.0100.17030.18
5.3.290.0170.16329.55
5.3.280.0230.17029.52
5.3.270.0070.18329.41
5.3.260.0270.15329.46
5.3.250.0370.10329.53
5.3.240.0200.15729.30
5.3.230.0100.17029.43
5.3.220.0100.16329.27
5.3.210.0130.16029.50
5.3.200.0170.14729.34
5.3.190.0170.15329.27
5.3.180.0270.13329.36
5.3.170.0030.17729.39
5.3.160.0270.14729.49
5.3.150.0070.14029.23
5.3.140.0170.14729.57
5.3.130.0100.17029.56
5.3.120.0030.11329.25
5.3.110.0100.16329.57
5.3.100.0130.15728.83
5.3.90.0170.11328.95
5.3.80.0070.17028.88
5.3.70.0270.14028.99
5.3.60.0070.12028.63
5.3.50.0130.14728.80
5.3.40.0170.15328.65
5.3.30.0230.14328.79
5.3.20.0230.14728.36
5.3.10.0100.16328.37
5.3.00.0270.15328.59
5.2.170.0130.16324.51
5.2.160.0200.16724.61
5.2.150.0100.16724.43
5.2.140.0130.14324.42
5.2.130.0100.17324.25
5.2.120.0100.17324.34
5.2.110.0230.17024.47
5.2.100.0200.15325.66
5.2.90.0170.17724.47
5.2.80.0070.17724.35
5.2.70.0070.16024.48
5.2.60.0300.16324.29
5.2.50.0200.16724.17
5.2.40.0170.17724.47
5.2.30.0000.17724.20
5.2.20.0100.16324.14
5.2.10.0100.14024.04
5.2.00.0300.13023.98
5.1.60.0100.14728.21
5.1.50.0100.18328.23
5.1.40.0130.13028.01
5.1.30.0070.16328.32
5.1.20.0030.12028.56
5.1.10.0130.16328.17
5.1.00.0100.16728.30
5.0.50.0100.24026.79
5.0.40.0470.22026.41
5.0.30.0100.25026.07
5.0.20.0070.22726.27
5.0.10.0100.22326.02
5.0.00.0100.23026.01
4.4.90.0200.19323.87
4.4.80.0130.19023.83
4.4.70.0070.16723.93
4.4.60.0070.19023.84
4.4.50.0200.17723.94
4.4.40.0030.21023.79
4.4.30.0100.19723.79
4.4.20.0000.22723.93
4.4.10.0100.20723.92
4.4.00.0170.19323.91
4.3.110.0130.20723.79
4.3.100.0100.20723.76
4.3.90.0070.22023.85
4.3.80.0200.21723.74
4.3.70.0100.22323.70
4.3.60.0070.23723.69
4.3.50.0030.21023.84
4.3.40.0100.21323.73
4.3.30.0070.22322.50
4.3.20.0070.22322.43
4.3.10.0030.24022.46
4.3.00.0170.22722.49

preferences:
35.2 ms | 401 KiB | 5 Q