3v4l.org

run code in 300+ PHP versions simultaneously
<?php class ColumnFieldsIterator implements \IteratorAggregate { public function getIterator() { return new ArrayIterator(['columns2','columns']); } } class RowFieldsIterator implements \IteratorAggregate { public function getIterator() { return new ArrayIterator(['rows2','rows']); } } class AllIterator implements \IteratorAggregate { public function getIterator() { $iterator = new AppendIterator; $iterator->append(new ColumnFieldsIterator); $iterator->append(new RowFieldsIterator); return $iterator ; } } $all = new AllIterator; foreach ($all as $k => $v) { echo "$k => $v\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)
8.3.60.0110.00316.63
8.3.50.0090.00921.08
8.3.40.0110.00418.83
8.3.30.0150.00018.76
8.3.20.0070.00020.22
8.3.10.0050.00323.65
8.3.00.0040.00423.61
8.2.180.0120.00918.41
8.2.170.0090.00622.96
8.2.160.0090.00619.44
8.2.150.0070.00024.18
8.2.140.0060.00324.66
8.2.130.0080.00019.85
8.2.120.0040.00426.35
8.2.110.0030.00622.27
8.2.100.0080.00418.04
8.2.90.0030.00519.05
8.2.80.0030.00717.97
8.2.70.0080.00017.63
8.2.60.0040.00418.04
8.2.50.0040.00418.07
8.2.40.0050.00222.26
8.2.30.0040.00419.37
8.2.20.0070.00017.66
8.2.10.0080.00317.97
8.2.00.0050.00317.93
8.1.280.0150.00025.92
8.1.270.0000.00823.82
8.1.260.0000.00826.35
8.1.250.0050.00328.09
8.1.240.0060.00323.81
8.1.230.0040.00819.16
8.1.220.0030.00617.77
8.1.210.0040.00418.77
8.1.200.0090.00017.38
8.1.190.0050.00317.38
8.1.180.0000.00818.10
8.1.170.0050.00318.57
8.1.160.0000.00720.78
8.1.150.0040.00418.85
8.1.140.0050.00519.64
8.1.130.0030.00317.72
8.1.120.0080.00017.50
8.1.110.0000.00717.52
8.1.100.0030.00617.44
8.1.90.0040.00417.46
8.1.80.0050.00317.47
8.1.70.0000.00717.45
8.1.60.0030.00517.60
8.1.50.0030.00617.55
8.1.40.0000.00817.40
8.1.30.0030.00517.64
8.1.20.0000.00817.63
8.1.10.0040.00417.50
8.1.00.0060.00317.52
8.0.300.0000.00718.77
8.0.290.0050.00216.63
8.0.280.0000.00818.38
8.0.270.0000.00817.14
8.0.260.0030.00317.13
8.0.250.0000.00716.95
8.0.240.0000.00817.04
8.0.230.0030.00316.90
8.0.220.0040.00416.85
8.0.210.0020.00517.03
8.0.200.0030.00316.89
8.0.190.0060.00317.02
8.0.180.0000.00716.99
8.0.170.0040.00417.02
8.0.160.0000.00717.03
8.0.150.0000.00716.89
8.0.140.0070.00016.90
8.0.130.0030.00313.35
8.0.120.0030.00516.99
8.0.110.0030.00317.03
8.0.100.0000.00716.92
8.0.90.0070.00016.96
8.0.80.0090.00616.89
8.0.70.0050.00316.95
8.0.60.0070.00016.80
8.0.50.0070.00016.85
8.0.30.0060.01117.11
8.0.20.0100.00917.40
8.0.10.0050.00317.12
8.0.00.0120.00616.97
7.4.330.0020.00216.89
7.4.320.0000.00716.51
7.4.300.0040.00416.49
7.4.290.0030.00316.52
7.4.280.0030.00616.45
7.4.270.0070.00016.60
7.4.260.0000.00716.49
7.4.250.0040.00416.56
7.4.240.0050.00216.54
7.4.230.0070.00016.59
7.4.220.0040.01416.68
7.4.210.0100.00516.59
7.4.200.0030.00316.63
7.4.160.0040.01116.57
7.4.150.0100.00717.40
7.4.140.0100.00917.86
7.4.130.0140.01116.51
7.4.120.0130.00616.54
7.4.110.0060.01316.74
7.4.100.0070.01016.50
7.4.90.0070.01016.41
7.4.80.0070.01019.39
7.4.70.0070.01016.52
7.4.60.0130.00316.44
7.4.50.0060.00916.54
7.4.40.0060.01216.72
7.4.30.0030.01316.30
7.4.00.0030.01215.04
7.3.330.0030.00313.17
7.3.320.0000.00613.46
7.3.310.0000.00716.39
7.3.300.0000.00716.40
7.3.290.0000.00716.41
7.3.280.0090.01016.38
7.3.270.0000.01817.40
7.3.260.0070.01016.47
7.3.240.0100.00916.64
7.3.230.0070.01016.39
7.3.210.0090.01016.62
7.3.200.0140.00719.39
7.3.190.0150.00416.56
7.3.180.0130.00316.54
7.3.170.0060.01316.51
7.3.160.0080.01116.42
7.3.120.0120.00615.08
7.3.110.0100.00715.04
7.3.100.0100.00614.98
7.3.90.0070.00714.46
7.3.80.0000.01715.01
7.3.70.0000.01714.88
7.3.60.0030.01414.99
7.3.50.0030.01214.64
7.3.40.0070.01114.89
7.3.30.0070.00414.88
7.3.20.0030.01316.57
7.3.10.0070.00716.73
7.3.00.0030.01016.61
7.2.330.0030.01416.88
7.2.320.0030.01616.46
7.2.310.0170.00016.53
7.2.300.0100.00716.78
7.2.290.0170.00416.41
7.2.250.0040.01415.00
7.2.240.0100.01014.94
7.2.230.0040.01215.20
7.2.220.0130.00715.05
7.2.210.0090.00314.93
7.2.200.0040.00415.04
7.2.190.0070.00714.66
7.2.180.0130.00314.95
7.2.170.0060.01215.05
7.2.60.0070.01016.92
7.2.00.0040.01119.17
7.1.330.0030.01115.75
7.1.320.0060.01015.79
7.1.310.0060.00615.81
7.1.300.0070.00715.69
7.1.290.0110.00315.46
7.1.280.0060.00315.62
7.1.270.0110.00415.70
7.1.260.0080.00815.75
7.1.200.0040.00715.67
7.1.100.0030.00918.09
7.1.70.0030.01416.78
7.1.60.0070.01819.27
7.1.50.0070.01316.86
7.1.00.0000.07722.32
7.0.200.0040.00716.73
7.0.60.0130.04021.84
7.0.50.0100.06017.88
7.0.40.0000.05020.19
7.0.30.0270.04720.16
7.0.20.0230.04020.30
7.0.10.0070.04020.07
7.0.00.0100.09020.20
5.6.280.0070.02721.03
5.6.210.0070.08720.56
5.6.200.0070.04718.18
5.6.190.0100.07320.65
5.6.180.0270.05020.56
5.6.170.0370.07320.73
5.6.160.0130.07320.57
5.6.150.0000.05318.25
5.6.140.0030.07718.18
5.6.130.0130.07318.14
5.6.120.0070.07721.00
5.6.110.0130.06021.09
5.6.100.0030.08320.98
5.6.90.0070.06721.02
5.6.80.0170.06320.54
5.5.350.0170.07020.35
5.5.340.0100.07718.04
5.5.330.0070.07720.25
5.5.320.0270.06020.30
5.5.310.0370.06720.23
5.5.300.0030.04017.98
5.5.290.0100.07718.08
5.5.280.0000.04720.79
5.5.270.0100.04720.77
5.5.260.0130.08020.73
5.5.250.0130.05320.62
5.5.240.0070.03720.16

preferences:
47.85 ms | 401 KiB | 5 Q