3v4l.org

run code in 300+ PHP versions simultaneously
<?php class obj implements arrayaccess { private $container = array(); public function __construct() { $this->container = array( "one" => 1, "two" => 2, "three" => 3, ); } public function offsetSet($offset, $value) { var_dump($offset); if (empty($offset)) { $this->container[] = $value; } else { $this->container[$offset] = $value; } } public function offsetExists($offset) { return isset($this->container[$offset]); } public function offsetUnset($offset) { unset($this->container[$offset]); } public function offsetGet($offset) { return isset($this->container[$offset]) ? $this->container[$offset] : null; } } $obj = new obj; $obj = 'Append 1'; print_r($obj);

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.00418.43
8.3.50.0140.00321.14
8.3.40.0070.00718.67
8.3.30.0140.00020.17
8.3.20.0080.00020.01
8.3.10.0060.00322.11
8.3.00.0050.00322.52
8.2.180.0100.00716.38
8.2.170.0160.00022.96
8.2.160.0070.01022.21
8.2.150.0040.00424.18
8.2.140.0050.00324.66
8.2.130.0050.00226.16
8.2.120.0030.00520.81
8.2.110.0030.00619.30
8.2.100.0080.00318.03
8.2.90.0020.00519.22
8.2.80.0080.00019.21
8.2.70.0040.00417.50
8.2.60.0060.00317.91
8.2.50.0060.00318.07
8.2.40.0040.00418.21
8.2.30.0080.00019.37
8.2.20.0080.00017.73
8.2.10.0070.00017.74
8.2.00.0060.00217.76
8.1.280.0100.00325.92
8.1.270.0040.00423.99
8.1.260.0070.00726.35
8.1.250.0080.00628.09
8.1.240.0050.00522.59
8.1.230.0110.00020.89
8.1.220.0040.00418.77
8.1.210.0050.00319.06
8.1.200.0030.00617.23
8.1.190.0050.00317.43
8.1.180.0060.00318.10
8.1.170.0040.00418.50
8.1.160.0070.00318.82
8.1.150.0030.00518.66
8.1.140.0040.00417.50
8.1.130.0030.00317.76
8.1.120.0000.00717.52
8.1.110.0040.00417.37
8.1.100.0070.00017.48
8.1.90.0000.00717.46
8.1.80.0040.00417.35
8.1.70.0000.00817.38
8.1.60.0000.00917.62
8.1.50.0000.00817.56
8.1.40.0080.00417.61
8.1.30.0030.00617.65
8.1.20.0030.00517.50
8.1.10.0050.00317.56
8.1.00.0030.00617.45
8.0.300.0060.00319.98
8.0.290.0000.00717.05
8.0.280.0030.00318.44
8.0.270.0000.00717.18
8.0.260.0030.00316.82
8.0.250.0000.00716.85
8.0.240.0030.00616.95
8.0.230.0050.00316.98
8.0.220.0080.00016.95
8.0.210.0000.00716.92
8.0.200.0050.00216.89
8.0.190.0050.00316.96
8.0.180.0080.00016.85
8.0.170.0060.00316.95
8.0.160.0050.00216.89
8.0.150.0000.00816.95
8.0.140.0000.01016.91
8.0.130.0030.00313.36
8.0.120.0030.00616.75
8.0.110.0000.00716.85
8.0.100.0000.00816.79
8.0.90.0000.00716.91
8.0.80.0090.00916.90
8.0.70.0000.00716.77
8.0.60.0030.00616.91
8.0.50.0070.00016.84
8.0.30.0080.01217.16
8.0.20.0080.00917.40
8.0.10.0050.00316.99
8.0.00.0140.00816.76
7.4.330.0050.00016.72
7.4.320.0000.00816.41
7.4.300.0000.00716.54
7.4.290.0060.00016.62
7.4.280.0000.00716.55
7.4.270.0000.00716.62
7.4.260.0050.00013.31
7.4.250.0080.00016.50
7.4.240.0050.00216.54
7.4.230.0030.00316.55
7.4.220.0070.01016.54
7.4.210.0100.00616.61
7.4.200.0040.00416.36
7.4.190.0040.00416.66
7.4.160.0040.01216.49
7.4.150.0060.01217.40
7.4.140.0080.00917.86
7.4.130.0110.00616.39
7.4.120.0090.00816.52
7.4.110.0100.00716.69
7.4.100.0110.00716.68
7.4.90.0110.00616.39
7.4.80.0100.00719.39
7.4.70.0060.00916.49
7.4.60.0160.00016.43
7.4.50.0030.00516.43
7.4.40.0030.01022.77
7.4.30.0130.00316.62
7.4.00.0080.00914.80
7.3.330.0050.00013.25
7.3.320.0000.00613.14
7.3.310.0060.00016.40
7.3.300.0050.00216.16
7.3.290.0070.00716.29
7.3.280.0090.01016.33
7.3.270.0110.00717.40
7.3.260.0120.01216.34
7.3.250.0100.01016.32
7.3.240.0190.00616.36
7.3.230.0090.00916.39
7.3.210.0120.00616.61
7.3.200.0090.00919.39
7.3.190.0140.00316.25
7.3.180.0090.01216.52
7.3.170.0100.00716.57
7.3.160.0050.01016.33
7.3.120.0080.00814.74
7.3.110.0070.00914.69
7.3.100.0070.00614.84
7.3.90.0030.01214.89
7.3.80.0060.01014.65
7.3.70.0020.01114.88
7.3.60.0050.00714.75
7.3.50.0050.00814.65
7.3.40.0010.01014.75
7.3.30.0060.00714.89
7.3.20.0070.00816.70
7.3.10.0080.00716.65
7.3.00.0070.00616.63
7.2.330.0090.00916.71
7.2.320.0110.01216.71
7.2.310.0070.01016.53
7.2.300.0070.01016.54
7.2.290.0100.00616.46
7.2.250.0040.01414.98
7.2.240.0080.01015.01
7.2.230.0110.00715.00
7.2.220.0050.00915.05
7.2.210.0090.00814.90
7.2.200.0050.00815.01
7.2.190.0090.00514.87
7.2.180.0100.00315.08
7.2.170.0080.00414.97
7.2.60.0070.00716.98
7.1.330.0080.00615.72
7.1.320.0090.00615.65
7.1.310.0060.00915.71
7.1.300.0070.00615.72
7.1.290.0070.00715.86
7.1.280.0040.00715.77
7.1.270.0010.01615.66
7.1.260.0060.00615.75
7.1.200.0000.01315.80
7.1.70.0030.00617.19
7.1.60.0070.01719.17
7.1.50.0110.01116.95
7.1.00.0100.07722.43
7.0.200.0000.00916.69
7.0.140.0130.06322.15
7.0.100.0170.07719.96
7.0.90.0200.05719.99
7.0.80.0130.07319.84
7.0.70.0200.09019.97
7.0.60.0130.07719.93
7.0.50.0070.05020.28
7.0.40.0130.07720.04
7.0.30.0070.04719.96
7.0.20.0030.04720.05
7.0.10.0130.07720.11
7.0.00.0000.08319.98
5.6.280.0100.06721.08
5.6.250.0070.09020.68
5.6.240.0270.06320.47
5.6.230.0200.07320.47
5.6.220.0000.08720.51
5.6.210.0000.08320.73
5.6.200.0100.07721.08
5.6.190.0030.06321.09
5.6.180.0100.08020.91
5.6.170.0070.08320.99
5.6.160.0030.09020.98
5.6.150.0070.08021.07
5.6.140.0030.07021.05
5.6.130.0100.08021.02
5.6.120.0030.08321.07
5.6.110.0170.07320.99
5.6.100.0070.08321.00
5.6.90.0100.07721.04
5.6.80.0130.04020.41
5.6.70.0100.07720.28
5.6.60.0130.09020.44
5.6.50.0130.05320.30
5.6.40.0100.07720.27
5.6.30.0070.05020.38
5.6.20.0100.05020.42
5.6.10.0100.08020.35
5.6.00.0130.07020.37
5.5.380.0070.05720.36
5.5.370.0130.05020.38
5.5.360.0130.07720.30
5.5.350.0130.07020.33
5.5.340.0070.07720.82
5.5.330.0130.06020.84
5.5.320.0070.07720.60
5.5.310.0030.08720.86
5.5.300.0170.07720.60
5.5.290.0000.09020.70
5.5.280.0070.06320.85
5.5.270.0100.06720.82
5.5.260.0070.04020.89
5.5.250.0170.07320.68
5.5.240.0100.07320.24
5.5.230.0200.07320.26
5.5.220.0170.06320.23
5.5.210.0000.05320.27
5.5.200.0030.07020.25
5.5.190.0030.08320.23
5.5.180.0130.07720.18
5.5.160.0130.07020.08
5.5.150.0130.06720.10
5.5.140.0200.07020.13
5.5.130.0030.08320.10
5.5.120.0130.07020.14
5.5.110.0170.06719.94
5.5.100.0070.07720.02
5.5.90.0070.07320.13
5.5.80.0130.07020.04
5.5.70.0030.04720.01
5.5.60.0070.08020.02
5.5.50.0170.07020.02
5.5.40.0130.07320.07
5.5.30.0170.06320.05
5.5.20.0170.07319.96
5.5.10.0230.06320.06
5.5.00.0030.08320.04
5.4.450.0100.07719.36
5.4.440.0000.08719.18
5.4.430.0100.04019.38
5.4.420.0070.08019.55
5.4.410.0070.06719.32
5.4.400.0000.09718.88
5.4.390.0100.06018.88
5.4.380.0100.06019.12
5.4.370.0100.07319.14
5.4.360.0100.04319.21
5.4.350.0070.06019.23
5.4.340.0130.06719.04
5.4.320.0070.08019.25
5.4.310.0200.07019.03
5.4.300.0070.05319.17
5.4.290.0130.06719.18
5.4.280.0070.06019.05
5.4.270.0070.08018.90
5.4.260.0100.06718.88
5.4.250.0100.05319.13
5.4.240.0070.05019.12
5.4.230.0030.08019.04
5.4.220.0100.07319.09
5.4.210.0170.07018.88
5.4.200.0100.07718.84
5.4.190.0070.08018.84
5.4.180.0030.08019.02
5.4.170.0030.07319.08
5.4.160.0130.07019.10
5.4.150.0170.03718.80
5.4.140.0130.06716.32
5.4.130.0070.08016.37
5.4.120.0170.06716.35
5.4.110.0130.06316.39
5.4.100.0070.07316.35
5.4.90.0070.06016.28
5.4.80.0070.07316.46
5.4.70.0100.04016.41
5.4.60.0030.07016.49
5.4.50.0130.06716.40
5.4.40.0170.06316.35
5.4.30.0070.06716.32
5.4.20.0000.05016.33
5.4.10.0030.07716.44
5.4.00.0030.07315.64
5.3.290.0130.07014.82
5.3.280.0000.08714.67
5.3.270.0070.05014.73
5.3.260.0100.07714.60
5.3.250.0100.04014.62
5.3.240.0070.05714.54
5.3.230.0100.07014.71
5.3.220.0070.07314.51
5.3.210.0000.07314.55
5.3.200.0030.07314.55
5.3.190.0070.06714.51
5.3.180.0030.08014.50
5.3.170.0000.05714.70
5.3.160.0100.05714.60
5.3.150.0130.07314.63
5.3.140.0070.03714.68
5.3.130.0000.07714.57
5.3.120.0100.07314.63
5.3.110.0130.06314.58
5.3.100.0000.05013.98
5.3.90.0030.07014.10
5.3.80.0030.07314.12
5.3.70.0070.07314.02
5.3.60.0070.04014.02
5.3.50.0130.06713.86
5.3.40.0070.04714.04
5.3.30.0070.05313.91
5.3.20.0100.06713.70
5.3.10.0070.06313.80
5.3.00.0100.05013.66
5.2.170.0100.05711.05
5.2.160.0030.06311.04
5.2.150.0000.05011.04
5.2.140.0000.05711.14
5.2.130.0030.05311.10
5.2.120.0070.04711.01
5.2.110.0130.05011.04
5.2.100.0000.05711.22
5.2.90.0030.06010.97
5.2.80.0000.06011.04
5.2.70.0070.04711.22
5.2.60.0070.05311.05
5.2.50.0070.03311.17
5.2.40.0030.06310.91
5.2.30.0030.06011.04
5.2.20.0100.06010.96
5.2.10.0030.05310.86
5.2.00.0100.03310.78
5.1.60.0130.04010.09
5.1.50.0100.05310.00
5.1.40.0030.0579.99
5.1.30.0130.04710.47
5.1.20.0070.05310.35
5.1.10.0000.05710.09
5.1.00.0100.04310.20
5.0.50.0070.0409.51
5.0.40.0000.0409.51
5.0.30.0100.0309.51
5.0.20.0100.0379.51
5.0.10.0030.0439.51
5.0.00.0030.0639.51
4.4.90.0070.0309.51
4.4.80.0030.0209.51
4.4.70.0000.0279.51
4.4.60.0000.0379.51
4.4.50.0070.0239.51
4.4.40.0100.0439.51
4.4.30.0000.0379.51
4.4.20.0070.0309.51
4.4.10.0070.0339.51
4.4.00.0000.0439.51
4.3.110.0030.0279.51
4.3.100.0030.0339.51
4.3.90.0100.0279.51
4.3.80.0030.0479.51
4.3.70.0070.0279.51
4.3.60.0070.0279.51
4.3.50.0000.0379.51
4.3.40.0000.0439.51
4.3.30.0030.0309.51
4.3.20.0000.0409.51
4.3.10.0000.0379.51
4.3.00.0000.0379.51

preferences:
74.25 ms | 400 KiB | 5 Q