3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Foo { public $bar = 1; public $baz = 2; public $qux = 3; } $a = []; for ($i = 0; $i < 1000; $i++) { $a[] = new Foo(); } var_dump(memory_get_usage()); foreach ($a as $o) { foreach ($o as $p) {} } var_dump(memory_get_usage());

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)
8.1.130.0060.00617.98
8.1.120.0040.00817.86
8.1.110.0120.00317.86
8.1.100.0080.00818.06
8.1.90.0150.00018.02
8.1.80.0110.00317.97
8.1.70.0090.00017.86
8.1.60.0050.00518.17
8.1.50.0110.00717.98
8.1.40.0100.00618.01
8.1.30.0120.00318.02
8.1.20.0080.00518.04
8.1.10.0150.00617.93
8.1.00.0100.00717.89
8.0.260.0030.00617.23
8.0.250.0120.00017.39
8.0.240.0070.00417.32
8.0.230.0030.00717.38
8.0.220.0030.00717.12
8.0.210.0080.00817.19
8.0.200.0070.00717.20
8.0.190.0110.00417.32
8.0.180.0130.00317.28
8.0.170.0130.00417.30
8.0.160.0110.00417.34
8.0.150.0130.00417.24
8.0.140.0160.00217.21
8.0.130.0140.00417.21
8.0.120.0090.00415.16
8.0.110.0110.00415.33
8.0.100.0110.00415.32
8.0.90.0100.00515.32
8.0.80.0100.00515.31
8.0.70.0100.00515.30
8.0.60.0110.00515.32
8.0.50.0100.00615.32
8.0.30.0110.00515.33
8.0.20.0130.00315.38
8.0.10.0100.00515.53
8.0.00.0040.00615.54
7.4.330.0080.00516.95
7.4.320.0140.00416.95
7.4.300.0110.00516.95
7.4.290.0130.00616.98
7.4.280.0060.00616.91
7.4.270.0130.00416.92
7.4.260.0140.00416.94
7.4.250.0130.00415.18
7.4.240.0120.00515.15
7.4.230.0130.00415.18
7.4.220.0120.00415.17
7.4.210.0120.00415.16
7.4.200.0110.00515.15
7.4.190.0110.00415.21
7.4.180.0110.00515.20
7.4.160.0110.00415.18
7.4.150.0110.00415.13
7.4.140.0110.00515.07
7.4.130.0110.00515.05
7.4.120.0110.00415.11
7.4.110.0120.00415.08
7.4.100.0110.00415.11
7.4.90.0110.00415.05
7.4.80.0100.00615.08
7.4.70.0110.00415.06
7.4.60.0120.00315.04
7.4.50.0100.00514.96
7.4.40.0120.00214.97
7.4.30.0100.00415.06
7.4.20.0090.00615.03
7.4.10.0110.00415.04
7.4.00.0110.00315.04
7.3.330.0110.00516.32
7.3.320.0120.00314.99
7.3.310.0110.00515.03
7.3.300.0120.00315.03
7.3.290.0130.00314.97
7.3.280.0090.00615.06
7.3.270.0130.00215.03
7.3.260.0100.00415.02
7.3.250.0120.00315.01
7.3.240.0090.00415.00
7.3.230.0100.00415.00
7.3.220.0120.00314.96
7.3.210.0100.00514.94
7.3.200.0110.00414.92
7.3.190.0110.00414.93
7.3.180.0130.00314.96
7.3.170.0110.00314.90
7.3.160.0100.00514.92
7.3.150.0110.00314.94
7.3.140.0090.00514.94
7.3.130.0100.00414.92
7.3.120.0090.00414.93
7.3.110.0090.00514.90
7.3.100.0090.00514.92
7.3.90.0090.00415.19
7.3.80.0080.00514.96
7.3.70.0100.00315.09
7.3.60.0090.00315.08
7.3.50.0100.00415.09
7.3.40.0080.00515.13
7.3.30.0100.00315.08
7.3.20.0110.00316.13
7.3.10.0100.00416.11
7.3.00.0100.00316.13

preferences:
13.54 ms | 403 KiB | 5 Q