3v4l.org

run code in 300+ PHP versions simultaneously
<?php class ObjectWithReferences { protected $var1; protected $var2; public function __construct() { $this->var1 = new StdClass(); $this->var2 = $this->var1; } } class WrapperObject implements Serializable { private $obj; public function __construct($obj) { $this->obj = $obj; } public function getObject() { return $this->obj; } public function serialize() { for ($i = 0; $i < 15; ++$i) { var_dump(serialize(new \stdClass())); } return serialize($this->obj); } public function unserialize($serialized) { $this->obj = unserialize($serialized); } } $wrapper = new WrapperObject(new ObjectWithReferences()); var_dump($wrapper->getObject()); $serialized = serialize($wrapper); var_dump($serialized); $wrapper = unserialize($serialized);

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.75
8.3.50.0130.00717.48
8.3.40.0100.00618.85
8.3.30.0070.00718.86
8.3.20.0040.00418.63
8.3.10.0050.00320.53
8.3.00.0080.00019.25
8.2.180.0060.01317.00
8.2.170.0130.00722.96
8.2.160.0070.00721.19
8.2.150.0000.00824.18
8.2.140.0080.00024.66
8.2.130.0000.00726.16
8.2.120.0040.00418.97
8.2.110.0060.00319.39
8.2.100.0110.00017.72
8.2.90.0050.00317.63
8.2.80.0080.00018.78
8.2.70.0000.00817.50
8.2.60.0080.00017.63
8.2.50.0050.00317.55
8.2.40.0040.00418.16
8.2.30.0090.00018.02
8.2.20.0030.00517.71
8.2.10.0040.00417.71
8.2.00.0000.00817.84
8.1.280.0170.00725.92
8.1.270.0080.00024.66
8.1.260.0030.00526.35
8.1.250.0040.00428.09
8.1.240.0030.00619.34
8.1.230.0040.00819.01
8.1.220.0030.00517.79
8.1.210.0030.00618.77
8.1.200.0040.00717.48
8.1.190.0030.00517.35
8.1.180.0050.00318.10
8.1.170.0030.00618.77
8.1.160.0000.00818.93
8.1.150.0090.00018.72
8.1.140.0000.00817.52
8.1.130.0020.00517.86
8.1.120.0000.00817.40
8.1.110.0080.00017.50
8.1.100.0080.00017.36
8.1.90.0060.00317.46
8.1.80.0050.00217.46
8.1.70.0070.00017.41
8.1.60.0000.00817.59
8.1.50.0040.00417.47
8.1.40.0040.00417.54
8.1.30.0020.00517.58
8.1.20.0090.00017.74
8.1.10.0040.00417.49
8.1.00.0060.00317.45
8.0.300.0000.00818.77
8.0.290.0020.00516.75
8.0.280.0030.00318.41
8.0.270.0030.00618.68
8.0.260.0030.00516.93
8.0.250.0050.00217.05
8.0.240.0000.00817.05
8.0.230.0000.00716.90
8.0.220.0070.00017.00
8.0.210.0030.00316.87
8.0.200.0000.00617.05
8.0.190.0000.00717.09
8.0.180.0080.00016.93
8.0.170.0000.00817.01
8.0.160.0050.00217.00
8.0.150.0040.00416.93
8.0.140.0080.00016.87
8.0.130.0000.00613.38
8.0.120.0000.00816.98
8.0.110.0000.00716.96
8.0.100.0040.00416.88
8.0.90.0040.00416.89
8.0.80.0000.01517.05
8.0.70.0000.00816.80
8.0.60.0080.00016.99
8.0.50.0040.00416.89
8.0.30.0130.00717.20
8.0.20.0100.00817.18
8.0.10.0000.00717.05
8.0.00.0150.00616.69
7.4.330.0050.00013.04
7.4.320.0050.00516.54
7.4.300.0060.00016.66
7.4.290.0040.00416.55
7.4.280.0040.00416.57
7.4.270.0030.00316.64
7.4.260.0000.00713.19
7.4.250.0060.00316.53
7.4.240.0010.00616.53
7.4.230.0040.00416.55
7.4.220.0140.00616.49
7.4.210.0050.01216.62
7.4.200.0000.00716.66
7.4.190.0030.00316.73
7.4.160.0060.01216.62
7.4.150.0110.00716.72
7.4.140.0090.00816.64
7.4.130.0140.00416.60
7.4.120.0120.00616.58
7.4.110.0060.01216.59
7.4.100.0090.01216.66
7.4.90.0090.00916.66
7.4.80.0090.00919.39
7.4.70.0100.00616.55
7.4.60.0120.00416.45
7.4.50.0080.00516.32
7.4.40.0070.00716.44
7.4.30.0070.01416.50
7.4.00.0030.01414.78
7.3.330.0070.00013.40
7.3.320.0030.00313.27
7.3.310.0030.00316.46
7.3.300.0070.00016.40
7.3.290.0060.00816.38
7.3.280.0100.00716.40
7.3.270.0090.00916.48
7.3.260.0120.00616.57
7.3.250.0100.01016.56
7.3.240.0070.01916.47
7.3.230.0140.00716.36
7.3.210.0060.01516.60
7.3.200.0110.00616.69
7.3.190.0070.01316.49
7.3.180.0130.00316.35
7.3.170.0070.01016.49
7.3.160.0040.01516.43
7.3.120.0110.00714.62
7.2.330.0130.00516.79
7.2.320.0140.00716.57
7.2.310.0090.01216.53
7.2.300.0070.01016.54
7.2.290.0090.00916.80
7.2.60.0060.00916.98
7.2.00.0000.01519.40
7.1.200.0060.00015.48
7.1.100.0040.00718.33
7.1.70.0030.00617.01
7.1.60.0110.01519.40
7.1.50.0030.01916.96
7.1.00.0000.03722.54
7.0.200.0000.01016.82
7.0.140.0030.07322.01
7.0.120.0000.07722.05
7.0.60.0100.04719.88
7.0.50.0030.08717.80
7.0.40.0000.04720.16
7.0.30.0270.06720.06
7.0.20.0270.08020.09
7.0.10.0230.04720.07
7.0.00.0130.04720.05
5.6.280.0000.07721.11
5.6.210.0100.07320.71
5.6.200.0070.05718.19
5.6.190.0070.07720.48
5.6.180.0300.07320.50
5.6.170.0200.03720.51
5.6.160.0100.08020.50
5.6.150.0070.07718.12
5.6.140.0130.06018.14
5.6.130.0070.03718.17
5.6.120.0100.07021.14
5.6.110.0070.07321.02
5.6.100.0170.08320.96
5.6.90.0100.08721.13
5.6.80.0030.07020.42
5.6.70.0070.03720.42
5.5.350.0330.07020.36
5.5.340.0070.05718.04
5.5.330.0100.03720.47
5.5.320.0200.03320.21
5.5.310.0300.03720.36
5.5.300.0100.03318.00
5.5.290.0130.07317.95
5.5.280.0070.08020.89
5.5.270.0100.05020.77
5.5.260.0170.06320.85
5.5.250.0000.04320.70
5.5.240.0070.06320.05
5.4.450.0070.08319.33
5.4.440.0000.05319.57
5.4.430.0070.08019.56
5.4.420.0100.06319.33
5.4.410.0030.08319.43
5.4.400.0100.04019.18
5.4.390.0070.03718.92
5.4.380.0070.05719.08
5.4.370.0230.03319.24
5.4.360.0070.05018.85
5.4.350.0070.03319.25
5.4.340.0030.06018.87
5.4.320.0070.06718.88
5.4.310.0100.07019.00
5.4.300.0030.07018.85
5.4.290.0170.04319.14
5.4.280.0100.07719.23
5.4.270.0170.04719.16
5.4.260.0070.06319.14
5.4.250.0130.07018.97
5.4.240.0170.04319.07
5.4.230.0030.04319.14
5.4.220.0030.07718.91
5.4.210.0170.03018.85
5.4.200.0130.05319.19
5.4.190.0200.06718.86
5.4.180.0100.04319.23
5.4.170.0030.08319.11
5.4.160.0100.07719.21
5.4.150.0130.07019.18
5.4.140.0130.05016.46
5.4.130.0130.03716.23
5.4.120.0170.06016.30
5.4.110.0030.07316.53
5.4.100.0000.08316.48
5.4.90.0030.07016.56
5.4.80.0070.07016.41
5.4.70.0070.06716.42
5.4.60.0000.04016.27
5.4.50.0000.04716.42
5.4.40.0170.06716.27
5.4.30.0030.06716.36
5.4.20.0100.06716.42
5.4.10.0100.07016.42
5.4.00.0070.07015.71
5.3.290.0030.08314.75
5.3.280.0030.05714.61
5.3.270.0100.07314.63
5.3.260.0130.07314.66
5.3.250.0070.08314.64
5.3.240.0100.07014.65
5.3.230.0070.06714.62
5.3.220.0100.07314.64
5.3.210.0070.05314.60
5.3.200.0130.06014.58
5.3.190.0070.08014.57
5.3.180.0070.07314.59
5.3.170.0130.05714.46
5.3.160.0070.04714.61
5.3.150.0100.07014.50
5.3.140.0100.04014.62
5.3.130.0070.07714.45
5.3.120.0030.07714.56
5.3.110.0030.04714.48
5.3.100.0130.07014.10
5.3.90.0070.06713.96
5.3.80.0000.04714.04
5.3.70.0030.06714.07
5.3.60.0100.05013.97
5.3.50.0100.05314.02
5.3.40.0030.04313.98
5.3.30.0070.07714.00
5.3.20.0070.04713.87
5.3.10.0000.05313.71
5.3.00.0030.05013.73
5.2.170.0070.05011.17
5.2.160.0030.03011.32
5.2.150.0100.02311.13
5.2.140.0070.03311.22
5.2.130.0000.05711.19
5.2.120.0100.05311.09
5.2.110.0030.06711.15
5.2.100.0000.04711.13
5.2.90.0070.06311.13
5.2.80.0070.04711.21
5.2.70.0070.06011.16
5.2.60.0100.04711.12
5.2.50.0070.04711.20
5.2.40.0000.03711.01
5.2.30.0000.06710.94
5.2.20.0000.03310.87
5.2.10.0030.06311.03
5.2.00.0070.04310.76
5.1.60.0030.0539.93
5.1.50.0070.03010.08
5.1.40.0070.0379.97
5.1.30.0130.05010.41
5.1.20.0070.05710.43
5.1.10.0070.03310.14
5.1.00.0100.04710.07
5.0.50.0000.0378.54
5.0.40.0030.0478.35
5.0.30.0000.0508.21
5.0.20.0030.0238.17
5.0.10.0070.0478.20
5.0.00.0070.0338.08
4.4.90.0000.0378.00
4.4.80.0000.0238.00
4.4.70.0000.0338.00
4.4.60.0030.0238.00
4.4.50.0030.0338.00
4.4.40.0000.0508.00
4.4.30.0000.0208.00
4.4.20.0000.0278.00
4.4.10.0000.0378.00
4.4.00.0030.0538.00
4.3.110.0000.0378.00
4.3.100.0000.0308.00
4.3.90.0000.0208.00
4.3.80.0030.0378.00
4.3.70.0000.0308.00
4.3.60.0030.0178.00
4.3.50.0070.0238.00
4.3.40.0000.0338.00
4.3.30.0000.0308.00
4.3.20.0030.0338.00
4.3.10.0030.0238.00
4.3.00.0030.0338.00

preferences:
57.81 ms | 400 KiB | 5 Q