3v4l.org

run code in 300+ PHP versions simultaneously
<?php class foo implements Iterator { public function __construct() { $this->position = 0; } function rewind() { $this->position = 0; } function current() { return $this->array[$this->position]; } function key() { return $this->position; } function next() { ++$this->position; } function valid() { return isset($this->array[$this->position]); } static function bar() { return "brap brap"; } } echo foo::bar(); $foo = new foo(); var_dump ($foo instanceOf Iterator);

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.0090.00616.50
8.3.50.0110.00817.36
8.3.40.0080.00818.71
8.3.30.0090.00618.63
8.3.20.0000.00818.79
8.3.10.0050.00518.81
8.3.00.0100.00019.31
8.2.180.0150.00016.50
8.2.170.0100.01022.96
8.2.160.0130.00318.96
8.2.150.0050.00324.18
8.2.140.0040.00424.66
8.2.130.0040.00426.16
8.2.120.0080.00020.93
8.2.110.0060.00321.03
8.2.100.0110.00017.91
8.2.90.0040.00419.23
8.2.80.0030.00618.16
8.2.70.0060.00317.38
8.2.60.0080.00018.03
8.2.50.0000.00817.93
8.2.40.0000.00819.23
8.2.30.0040.00417.66
8.2.20.0070.00317.63
8.2.10.0090.00017.72
8.2.00.0040.00417.60
8.1.280.0120.00925.92
8.1.270.0000.00723.99
8.1.260.0030.00526.35
8.1.250.0080.00028.09
8.1.240.0030.00621.29
8.1.230.0040.00817.77
8.1.220.0030.00517.74
8.1.210.0000.00818.77
8.1.200.0030.00617.22
8.1.190.0060.00317.35
8.1.180.0000.00718.71
8.1.170.0030.00617.62
8.1.160.0050.00219.02
8.1.150.0040.00418.50
8.1.140.0060.00317.44
8.1.130.0000.00719.23
8.1.120.0040.00417.52
8.1.110.0000.00717.42
8.1.100.0040.00417.52
8.1.90.0040.00417.42
8.1.80.0030.00317.45
8.1.70.0000.00817.46
8.1.60.0000.00817.56
8.1.50.0000.00817.45
8.1.40.0030.00617.54
8.1.30.0040.00417.64
8.1.20.0040.00417.51
8.1.10.0040.00417.43
8.1.00.0040.00417.48
8.0.300.0060.00618.77
8.0.290.0080.00016.63
8.0.280.0050.00318.49
8.0.270.0030.00317.17
8.0.260.0030.00316.69
8.0.250.0000.01016.86
8.0.240.0020.00516.95
8.0.230.0040.00416.92
8.0.220.0030.00316.88
8.0.210.0070.00016.86
8.0.200.0030.00316.92
8.0.190.0030.00616.84
8.0.180.0060.00316.97
8.0.170.0000.00716.91
8.0.160.0080.00017.00
8.0.150.0040.00416.85
8.0.140.0040.00416.82
8.0.130.0030.00313.31
8.0.120.0000.00916.85
8.0.110.0070.00016.93
8.0.100.0000.00816.92
8.0.90.0000.00817.00
8.0.80.0070.00716.82
8.0.70.0040.00416.98
8.0.60.0000.00816.92
8.0.50.0000.00816.95
8.0.30.0190.00417.18
8.0.20.0130.00817.19
8.0.10.0000.00716.99
8.0.00.0140.00816.90
7.4.330.0030.00312.89
7.4.320.0000.00616.48
7.4.300.0080.00016.39
7.4.290.0040.00416.55
7.4.280.0050.00316.52
7.4.270.0050.00216.46
7.4.260.0000.00613.30
7.4.250.0030.00516.48
7.4.240.0000.00716.50
7.4.230.0070.00016.57
7.4.220.0130.00716.45
7.4.210.0060.00916.61
7.4.200.0000.00716.30
7.4.190.0060.00216.47
7.4.160.0080.00816.39
7.4.150.0130.00616.51
7.4.140.0120.00617.86
7.4.130.0150.00616.54
7.4.120.0110.00716.63
7.4.110.0090.00916.62
7.4.100.0130.00316.60
7.4.90.0140.00416.55
7.4.80.0100.00719.39
7.4.70.0090.00616.47
7.4.60.0100.00716.61
7.4.50.0030.00616.25
7.4.40.0120.00216.38
7.4.30.0060.01216.59
7.4.00.0030.01314.69
7.3.330.0000.00613.23
7.3.320.0000.00513.28
7.3.310.0050.00316.38
7.3.300.0050.00216.33
7.3.290.0080.01016.38
7.3.280.0120.00316.38
7.3.270.0090.00916.41
7.3.260.0110.00716.41
7.3.240.0090.00916.38
7.3.230.0080.00816.36
7.3.210.0150.00416.47
7.3.200.0070.01016.29
7.3.190.0040.01416.68
7.3.180.0070.00716.48
7.3.170.0070.01016.52
7.3.160.0070.01016.40
7.3.120.0040.01114.90
7.2.330.0090.00916.77
7.2.320.0090.00916.40
7.2.310.0100.00716.71
7.2.300.0060.01216.79
7.2.290.0110.00616.74
7.1.100.0150.00418.05
7.1.70.0030.00617.09
7.1.60.0000.02019.25
7.1.50.0040.01116.66
7.1.00.0000.07722.44
7.0.200.0000.01016.82
7.0.140.0000.07722.10
7.0.120.0030.06722.15
7.0.60.0170.07319.86
7.0.50.0170.06717.90
7.0.40.0030.08320.13
7.0.30.0400.06320.16
7.0.20.0330.07720.15
7.0.10.0200.05720.07
7.0.00.0100.08020.05
5.6.280.0100.06721.16
5.6.210.0000.05020.47
5.6.200.0100.07718.18
5.6.190.0030.04320.46
5.6.180.0170.05020.36
5.6.170.0400.04020.47
5.6.160.0070.04020.46
5.6.150.0000.04718.16
5.6.140.0030.08018.16
5.6.130.0030.04018.21
5.6.120.0130.07321.10
5.6.110.0130.07721.00
5.6.100.0030.08720.98
5.6.90.0070.04321.11
5.6.80.0000.08720.41
5.6.70.4300.04020.53
5.5.350.0170.07720.34
5.5.340.0000.04017.96
5.5.330.0100.03320.57
5.5.320.0230.03320.44
5.5.310.0230.06320.33
5.5.300.0000.04717.98
5.5.290.0070.04717.97
5.5.280.0130.08020.63
5.5.270.0070.08320.98
5.5.260.0070.04020.85
5.5.250.0030.06720.48
5.5.240.0130.06320.16
5.4.450.0100.07719.58
5.4.440.0000.05719.47
5.4.430.0100.03719.44
5.4.420.0070.07319.24
5.4.410.0100.08019.38
5.4.400.0000.08019.21
5.4.390.0170.06718.87
5.4.380.0130.04719.07
5.4.370.0100.04318.88
5.4.360.0100.07318.85
5.4.350.0100.06319.21
5.4.340.0070.04019.26
5.4.320.0000.08018.87
5.4.310.0030.06318.88
5.4.300.0170.04019.07
5.4.290.0070.08019.00
5.4.280.0100.06018.98
5.4.270.0000.04718.84
5.4.260.0070.04719.23
5.4.250.0130.07019.14
5.4.240.0100.07718.87
5.4.230.0070.04018.85
5.4.220.0100.05019.16
5.4.210.0030.05019.15
5.4.200.0100.06319.23
5.4.190.0030.04719.14
5.4.180.0070.03719.11
5.4.170.0100.07019.23
5.4.160.0070.08019.22
5.4.150.0100.07319.18
5.4.140.0100.04716.25
5.4.130.0070.05716.44
5.4.120.0070.06016.39
5.4.110.0030.04316.28
5.4.100.0100.07016.67
5.4.90.0030.04316.54
5.4.80.0000.04316.38
5.4.70.0130.06316.44
5.4.60.0100.04316.28
5.4.50.0130.03316.43
5.4.40.0130.04016.39
5.4.30.0070.04716.64
5.4.20.0070.04316.34
5.4.10.0070.05716.40
5.4.00.0030.07715.98
5.3.290.0200.06014.74
5.3.280.0030.07014.61
5.3.270.0030.05714.78
5.3.260.0130.08714.77
5.3.250.0030.07714.62
5.3.240.0270.06014.50
5.3.230.0030.07314.63
5.3.220.0170.06314.64
5.3.210.0070.06314.58
5.3.200.0000.04314.46
5.3.190.0100.05314.58
5.3.180.0030.04314.73
5.3.170.0000.08714.57
5.3.160.0070.05314.60
5.3.150.0000.08014.57
5.3.140.0100.04714.71
5.3.130.0070.07314.59
5.3.120.0100.07714.61
5.3.110.0070.07714.61
5.3.100.0070.07314.06
5.3.90.0030.03714.08
5.3.80.0070.04014.05
5.3.70.0070.03314.11
5.3.60.0070.04013.93
5.3.50.0030.05313.91
5.3.40.0100.03013.98
5.3.30.0000.03713.94
5.3.20.0030.03313.70
5.3.10.0070.03013.72
5.3.00.0030.03313.70
5.2.170.0030.03011.21
5.2.160.0000.03311.11
5.2.150.0000.03011.19
5.2.140.0070.03011.20
5.2.130.0070.03011.00
5.2.120.0100.02711.00
5.2.110.0100.02311.08
5.2.100.0000.03011.13
5.2.90.0030.02711.16
5.2.80.0000.03011.07
5.2.70.0030.02711.18
5.2.60.0030.02711.04
5.2.50.0070.02311.02
5.2.40.0000.03011.00
5.2.30.0070.02311.13
5.2.20.0030.02711.02
5.2.10.0030.02710.86
5.2.00.0030.02710.73
5.1.60.0000.0279.98
5.1.50.0100.01710.00
5.1.40.0070.02010.05
5.1.30.0070.02310.49
5.1.20.0000.02710.41
5.1.10.0000.02710.14
5.1.00.0000.0309.98
5.0.50.0000.0208.60
5.0.40.0030.0178.56
5.0.30.0000.0338.42
5.0.20.0030.0178.42
5.0.10.0000.0208.42
5.0.00.0000.0308.42
4.4.90.0030.0138.42
4.4.80.0000.0138.42
4.4.70.0030.0138.42
4.4.60.0070.0108.42
4.4.50.0000.0138.42
4.4.40.0030.0238.42
4.4.30.0000.0178.42
4.4.20.0000.0178.42
4.4.10.0000.0178.42
4.4.00.0000.0238.42
4.3.110.0000.0178.42
4.3.100.0000.0138.42
4.3.90.0000.0138.42
4.3.80.0070.0208.42
4.3.70.0030.0108.42
4.3.60.0000.0138.42
4.3.50.0000.0138.42
4.3.40.0030.0208.42
4.3.30.0000.0138.42
4.3.20.0000.0138.42
4.3.10.0030.0138.42
4.3.00.0000.0178.42

preferences:
51.26 ms | 401 KiB | 5 Q