3v4l.org

run code in 300+ PHP versions simultaneously
<?php class I extends ArrayIterator { public function current() { return parent::current(); } } $a = new ArrayObject([1, 2, 3], 0, I::class); foreach ($a as $key => &$value) { $value += 10; } unset($value); var_dump($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)
8.1.100.0070.00017.40
8.1.90.0000.00817.39
8.1.80.0000.00817.45
8.1.70.0000.00717.34
8.1.60.0050.00317.43
8.1.50.0000.00817.54
8.1.40.0030.00617.48
8.1.30.0040.00417.48
8.1.20.0050.00317.54
8.1.10.0050.00317.48
8.1.00.0030.00717.39
8.0.230.0000.00716.90
8.0.220.0000.00716.93
8.0.210.0070.00016.93
8.0.200.0040.00417.01
8.0.190.0040.00416.91
8.0.180.0070.00016.98
8.0.170.0080.00016.88
8.0.160.0080.00016.95
8.0.150.0000.00717.01
8.0.140.0000.00716.99
8.0.130.0000.00513.36
8.0.120.0080.00016.82
8.0.110.0000.00716.82
8.0.100.0020.00516.96
8.0.90.0070.00016.96
8.0.80.0110.01417.02
8.0.70.0020.00516.82
8.0.60.0040.00416.76
8.0.50.0040.00416.81
8.0.30.0090.00917.20
8.0.20.0100.01117.40
8.0.10.0050.00217.06
8.0.00.0070.01116.90
7.4.300.0030.00316.56
7.4.290.0030.00316.56
7.4.280.0040.00416.58
7.4.270.0000.00916.55
7.4.260.0050.00316.60
7.4.250.0030.00316.41
7.4.240.0030.00316.51
7.4.230.0000.00716.60
7.4.220.0030.00516.63
7.4.210.0010.01316.65
7.4.200.0030.00316.70
7.4.160.0080.00716.47
7.4.140.0060.01217.86
7.4.130.0030.01316.42
7.4.120.0130.00816.49
7.4.110.0140.00316.68
7.4.100.0150.00616.50
7.4.90.0070.01116.58
7.4.80.0030.02119.39
7.4.70.0070.01016.36
7.4.60.0120.00916.51
7.4.50.0000.01516.46
7.4.40.0030.01316.51
7.4.00.0070.01214.91
7.3.330.0000.00613.36
7.3.320.0060.00013.36
7.3.310.0040.00416.40
7.3.300.0040.00416.40
7.3.290.0070.00016.32
7.3.280.0060.00916.43
7.3.260.0090.00816.48
7.3.240.0080.00916.40
7.3.230.0100.00716.46
7.3.210.0100.00816.47
7.3.200.0040.01216.52
7.3.190.0060.00916.44
7.3.180.0100.00616.57
7.3.170.0130.00416.35
7.3.160.0120.00316.34
7.3.120.0070.01115.07
7.3.110.0080.01214.85
7.3.100.0030.00614.94
7.3.90.0100.00314.75
7.3.80.0080.00815.02
7.3.70.0000.01415.01
7.3.60.0030.01214.81
7.3.50.0030.00714.87
7.3.40.0030.00614.86
7.3.30.0070.00414.67
7.3.20.0120.00016.62
7.3.10.0070.00716.66
7.3.00.0070.00316.61
7.2.330.0060.01216.31
7.2.320.0130.00316.66
7.2.310.0140.00416.40
7.2.300.0070.01016.63
7.2.290.0030.01616.39
7.2.250.0110.00715.07
7.2.240.0030.01715.15
7.2.230.0060.00914.98
7.2.220.0160.00015.17
7.2.210.0040.00714.94
7.2.200.0070.01114.57
7.2.190.0000.01914.77
7.2.180.0000.00914.98
7.2.170.0110.00414.90
7.2.60.0030.00916.73
7.2.40.1750.01018.01
7.2.30.1080.01017.84
7.2.20.1150.00717.90
7.2.10.1320.01017.98
7.2.00.1400.01017.85
7.1.330.0000.01515.79
7.1.320.0070.00815.80
7.1.310.0050.00315.38
7.1.300.0100.00615.59
7.1.290.0040.00715.57
7.1.280.0030.01015.84
7.1.270.0040.00815.58
7.1.260.0070.00715.57
7.1.200.0090.00615.72
7.1.160.1300.01016.81
7.1.150.1930.00816.71
7.1.140.1410.00316.64
7.1.130.1080.01116.79
7.1.120.1260.00616.36
7.1.110.0970.00816.30
7.1.100.1410.01016.10
7.1.90.1400.01315.98
7.1.80.1270.01216.14
7.1.70.1690.01014.85
7.1.60.1720.00933.17
7.1.50.1520.01432.53
7.1.40.1600.01032.47
7.1.30.1870.01132.74
7.1.20.1960.01532.65
7.1.10.1850.00714.62
7.1.00.1720.00814.87

preferences:
11.65 ms | 406 KiB | 5 Q