3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Foo extends IteratorIterator { function __construct( $items ) { if ( is_array( $items ) ) { $items = new ArrayIterator( $items ); } } function __debugInfo() { return [ "count" => iterator_count( $this ) ]; } } $a = new Foo( [ 1,2,3 ] ); 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.3.60.0070.00716.50
8.3.50.0110.01022.13
8.3.40.0070.00718.81
8.3.30.0120.00318.78
8.3.20.0080.00021.46
8.3.10.0060.00320.55
8.3.00.0070.00721.85
8.2.180.0090.00618.43
8.2.170.0000.01422.96
8.2.160.0100.00319.04
8.2.150.0040.00424.18
8.2.140.0040.00424.66
8.2.130.0060.00321.18
8.2.120.0070.00026.35
8.2.110.0030.00621.04
8.2.100.0080.00419.15
8.2.90.0000.00817.91
8.2.80.0080.00018.03
8.2.70.0000.00817.92
8.2.60.0000.00818.03
8.2.50.0050.00318.10
8.2.40.0000.00719.41
8.2.30.0000.00819.19
8.2.20.0000.00717.98
8.2.10.0000.00717.95
8.2.00.0000.00817.55
8.1.280.0070.01325.92
8.1.270.0000.00823.87
8.1.260.0070.00028.09
8.1.250.0080.00028.09
8.1.240.0090.00022.52
8.1.230.0040.00822.75
8.1.220.0030.00517.74
8.1.210.0000.00918.77
8.1.200.0060.00317.35
8.1.190.0090.00017.23
8.1.180.0030.00518.10
8.1.170.0080.00018.43
8.1.160.0040.00422.09
8.1.150.0040.00418.71
8.1.140.0040.00419.45
8.1.130.0050.00317.65
8.1.120.0040.00417.43
8.1.110.0030.00617.32
8.1.100.0050.00217.45
8.1.90.0030.00517.41
8.1.80.0000.00717.31
8.1.70.0070.00017.26
8.1.60.0000.00817.61
8.1.50.0050.00317.56
8.1.40.0080.00017.59
8.1.30.0080.00017.66
8.1.20.0030.00617.68
8.1.10.0000.00817.56
8.1.00.0040.00417.41
8.0.300.0000.00719.63
8.0.290.0000.01116.75
8.0.280.0040.00418.39
8.0.270.0030.00317.18
8.0.260.0060.00317.27
8.0.250.0070.00016.97
8.0.240.0070.00417.01
8.0.230.0030.00616.92
8.0.220.0000.00716.86
8.0.210.0030.00316.73
8.0.200.0030.00316.94
8.0.190.0000.00717.00
8.0.180.0000.00716.94
8.0.170.0000.00716.80
8.0.160.0000.00716.88
8.0.150.0000.00816.95
8.0.140.0030.00516.87
8.0.130.0050.00013.36
8.0.120.0040.00416.84
8.0.110.0050.00616.91
8.0.100.0040.00417.01
8.0.90.0000.00716.72
8.0.80.0070.01416.85
8.0.70.0070.00016.90
8.0.60.0000.00716.78
8.0.50.0000.00716.77
8.0.30.0050.01416.95
8.0.20.0110.00817.42
8.0.10.0000.00817.04
8.0.00.0100.00716.53
7.4.330.0050.00015.21
7.4.320.0070.00016.53
7.4.300.0000.00616.52
7.4.290.0020.00516.42
7.4.280.0040.00416.55
7.4.270.0000.00716.60
7.4.260.0000.00816.55
7.4.250.0030.00316.46
7.4.240.0050.00316.62
7.4.230.0000.00716.40
7.4.220.0030.01416.52
7.4.210.0090.01016.60
7.4.200.0030.00316.54
7.4.160.0080.01116.57
7.4.150.0070.01417.40
7.4.140.0140.00717.86
7.4.130.0090.01116.54
7.4.120.0080.00816.52
7.4.110.0100.01016.38
7.4.100.0140.00316.53
7.4.90.0140.00816.45
7.4.80.0080.00819.39
7.4.70.0070.01016.37
7.4.60.0050.01116.62
7.4.50.0100.00316.52
7.4.40.0090.00916.46
7.4.30.0070.01016.41
7.3.330.0000.00613.35
7.3.320.0030.00313.44
7.3.310.0000.00816.32
7.3.300.0070.00016.22
7.3.290.0100.00516.40
7.3.280.0120.00616.37
7.3.270.0110.00717.40
7.3.260.0110.00716.38
7.3.250.0040.01516.44
7.3.240.0080.01216.49
7.3.230.0130.00316.39
7.3.210.0190.00016.52
7.3.200.0060.00916.31
7.3.190.0170.00716.59
7.3.180.0100.01016.33
7.3.170.0150.00916.59
7.3.160.0100.00716.37
7.2.330.0070.00916.60
7.2.320.0070.01116.75
7.2.310.0030.01316.65
7.2.300.0080.01216.63
7.2.290.0080.00816.49
7.0.110.0030.03722.00
7.0.100.0030.03721.97
7.0.90.0030.04021.96
7.0.80.0030.03322.14
7.0.70.0070.03722.16
7.0.60.0070.03322.00
7.0.50.0030.03722.06
7.0.40.0000.04322.21
7.0.30.0000.04722.07
7.0.20.0070.04722.17
7.0.10.0030.03322.01
7.0.00.0000.03722.10
5.6.260.0070.03721.13
5.6.250.0070.04020.84
5.6.240.0000.04020.99
5.6.230.0070.03020.87
5.6.220.0000.04020.83
5.6.210.0030.05020.97
5.6.200.0030.03321.04
5.6.190.0000.04720.94
5.6.180.0000.04021.08
5.6.170.0000.03321.09
5.6.160.0070.03721.02
5.6.150.0000.04321.00
5.6.140.0070.03020.90
5.6.130.0070.04020.73
5.6.120.0000.04021.00
5.6.110.0030.03321.02
5.6.100.0000.03720.91
5.6.90.0030.03720.98
5.6.80.0000.03720.31
5.6.70.0030.03720.37
5.6.60.0100.03020.21
5.6.50.0000.03720.41
5.6.40.0030.03720.19
5.6.30.0030.03320.41
5.6.20.0100.03320.41
5.6.10.0070.03720.20
5.6.00.0070.03020.17
5.5.380.0000.03717.56
5.5.370.0030.03017.47
5.5.360.0030.04317.54
5.5.350.0030.03317.51
5.5.340.0000.04017.95
5.5.330.0000.04018.10
5.5.320.0000.04018.25
5.5.310.0070.03017.83
5.5.300.0070.03018.12
5.5.290.0000.05017.95
5.5.280.0000.04717.95
5.5.270.0030.03318.21
5.5.260.0000.03718.05
5.5.250.0030.03317.76
5.5.240.0030.03017.51
5.5.230.0000.04017.28
5.5.220.0000.04317.47
5.5.210.0000.03317.46
5.5.200.0000.03317.58
5.5.190.0000.03717.27
5.5.180.0000.04317.59
5.5.160.0070.03317.18
5.5.150.0000.04017.30
5.5.140.0000.05717.30
5.5.130.0000.03317.56
5.5.120.0030.03317.26
5.5.110.0000.03317.17
5.5.100.0000.03717.51
5.5.90.0000.04017.29
5.5.80.0070.03017.38
5.5.70.0030.04017.18
5.5.60.0030.03717.07
5.5.50.0070.02717.17
5.5.40.0030.03317.36
5.5.30.0070.03017.07
5.5.20.0030.03317.30
5.5.10.0030.03317.30
5.5.00.0000.03317.35
5.4.450.0030.04019.66
5.4.440.0030.04719.55
5.4.430.0070.03019.49
5.4.420.0000.03319.41
5.4.410.0000.04019.19
5.4.400.0000.03319.16
5.4.390.0000.03319.18
5.4.380.0070.02719.22
5.4.370.0070.02718.93
5.4.360.0030.03318.97
5.4.350.0030.03018.99
5.4.340.0000.03318.97
5.4.320.0030.03319.02
5.4.310.0030.03718.97
5.4.300.0030.05019.31
5.4.290.0000.03718.97
5.4.280.0030.03019.27
5.4.270.0000.03719.17
5.4.260.0030.03019.32
5.4.250.0000.03319.29
5.4.240.0000.03318.95
5.4.230.0000.03319.14
5.4.220.0070.03019.16
5.4.210.0030.03018.93
5.4.200.0000.03719.12
5.4.190.0030.04018.98
5.4.180.0000.03718.93
5.4.170.0030.03718.98
5.4.160.0000.03719.00
5.4.150.0030.05019.06
5.4.140.0000.04316.51
5.4.130.0030.04316.53
5.4.120.0070.03016.54
5.4.110.0000.03316.35
5.4.100.0030.03016.55
5.4.90.0030.03316.25
5.4.80.0030.03716.38
5.4.70.0000.03016.33
5.4.60.0030.03316.62
5.4.50.0000.03716.55
5.4.40.0000.04016.48
5.4.30.0000.03716.50
5.4.20.0070.03316.32
5.4.10.0030.03016.39
5.4.00.0100.02015.87
5.3.290.0000.04714.66
5.3.280.0030.03014.73
5.3.270.0000.03714.70
5.3.260.0000.03314.64
5.3.250.0000.03714.64
5.3.240.0000.03314.69
5.3.230.0030.04014.60
5.3.220.0030.03714.58
5.3.210.0030.03014.52
5.3.200.0000.03014.80
5.3.190.0000.04714.57
5.3.180.0030.03714.57
5.3.170.0000.04714.71
5.3.160.0030.03314.57
5.3.150.0000.05314.79
5.3.140.0030.03014.68
5.3.130.0070.03014.54
5.3.120.0030.03714.57
5.3.110.0070.03014.64
5.3.100.0030.02714.05
5.3.90.0000.03314.02
5.3.80.0030.02714.01
5.3.70.0000.03714.10
5.3.60.0000.03013.96
5.3.50.0000.03713.93
5.3.40.0030.03013.96
5.3.30.0030.03713.97
5.3.20.0000.04013.54
5.3.10.0000.03313.66
5.3.00.0030.04013.62
5.2.170.0000.02711.15
5.2.160.0070.03011.00
5.2.150.0000.03311.00
5.2.140.0000.03311.14
5.2.130.0030.02310.96
5.2.120.0000.02311.16
5.2.110.0000.02711.13
5.2.100.0030.02711.24
5.2.90.0030.03011.09
5.2.80.0000.03011.18
5.2.70.0070.02311.11
5.2.60.0000.02711.19
5.2.50.0000.03011.16
5.2.40.0070.03310.97
5.2.30.0030.03310.94
5.2.20.0000.03011.04
5.2.10.0030.02310.86
5.2.00.0000.02710.70
5.1.60.0000.02310.38
5.1.50.0030.02710.38
5.1.40.0070.02010.38
5.1.30.0030.02010.43
5.1.20.0030.02010.38
5.1.10.0000.02310.38
5.1.00.0000.02710.38
5.0.50.0070.01710.38
5.0.40.0030.01710.38
5.0.30.0030.02310.38
5.0.20.0000.02010.38
5.0.10.0030.02010.38
5.0.00.0000.02710.38
4.4.90.0000.01310.38
4.4.80.0000.02310.38
4.4.70.0000.01310.38
4.4.60.0000.01310.38
4.4.50.0000.01310.38
4.4.40.0000.03010.38
4.4.30.0030.01710.38
4.4.20.0000.02010.38
4.4.10.0000.01310.38
4.4.00.0000.02310.38
4.3.110.0030.01010.38
4.3.100.0000.01710.38
4.3.90.0000.01710.38
4.3.80.0000.02010.38
4.3.70.0000.01710.38
4.3.60.0000.01310.38
4.3.50.0030.01310.38
4.3.40.0000.02710.38
4.3.30.0000.01710.38
4.3.20.0000.01710.38
4.3.10.0000.01710.38
4.3.00.0000.01310.38

preferences:
71.96 ms | 401 KiB | 5 Q