3v4l.org

run code in 300+ PHP versions simultaneously
<?php class A { public $a = array(); public function __construct() { $this->a[] = new B(1); $this->a[] = new B(2); } } class B implements Serializable { public $b; public function __construct($c) { $this->b = new C($c); } public function serialize() { return serialize(clone $this->b); } public function unserialize($data) { $this->b = unserialize($data); } } class C { public $c; public function __construct($c) { $this->c = $c; } } $a = unserialize(serialize(new 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.0130.00318.43
8.3.50.0110.00521.97
8.3.40.0070.00718.59
8.3.30.0070.00718.92
8.3.20.0050.00320.33
8.3.10.0040.00421.98
8.3.00.0040.00422.23
8.2.180.0130.00618.66
8.2.170.0150.00022.96
8.2.160.0140.00420.93
8.2.150.0080.00024.18
8.2.140.0050.00324.66
8.2.130.0080.00026.16
8.2.120.0030.00519.48
8.2.110.0060.00322.12
8.2.100.0080.00419.64
8.2.90.0080.00019.21
8.2.80.0060.00319.66
8.2.70.0030.00617.63
8.2.60.0050.00317.93
8.2.50.0030.00618.07
8.2.40.0000.00818.26
8.2.30.0050.00318.11
8.2.20.0040.00417.70
8.2.10.0000.00817.80
8.2.00.0000.00817.64
8.1.280.0100.00725.92
8.1.270.0080.00023.87
8.1.260.0040.00426.35
8.1.250.0000.00828.09
8.1.240.0030.00623.92
8.1.230.0100.00019.15
8.1.220.0030.00517.79
8.1.210.0040.00418.77
8.1.200.0000.00917.35
8.1.190.0040.00417.66
8.1.180.0060.00318.10
8.1.170.0060.00318.68
8.1.160.0030.00322.01
8.1.150.0000.00720.47
8.1.140.0040.00417.45
8.1.130.0050.00217.82
8.1.120.0040.00417.49
8.1.110.0040.00417.36
8.1.100.0000.00717.41
8.1.90.0000.00717.40
8.1.80.0000.00717.36
8.1.70.0000.00717.40
8.1.60.0040.00417.58
8.1.50.0040.00417.57
8.1.40.0000.00817.57
8.1.30.0000.00817.62
8.1.20.0030.00617.71
8.1.10.0040.00417.55
8.1.00.0050.00217.39
8.0.300.0000.00718.77
8.0.290.0050.00317.18
8.0.280.0030.00318.43
8.0.270.0000.00717.25
8.0.260.0030.00316.89
8.0.250.0030.00316.93
8.0.240.0030.00317.05
8.0.230.0070.00016.90
8.0.220.0030.00316.84
8.0.210.0000.00716.86
8.0.200.0030.00317.05
8.0.190.0000.00817.03
8.0.180.0000.01017.00
8.0.170.0000.00716.86
8.0.160.0000.00816.94
8.0.150.0050.00316.98
8.0.140.0000.00816.95
8.0.130.0030.00413.37
8.0.120.0050.00316.98
8.0.110.0000.00716.86
8.0.100.0040.00416.80
8.0.90.0000.00816.92
8.0.80.0070.01616.93
8.0.70.0000.00716.75
8.0.60.0050.00216.85
8.0.50.0000.00717.02
8.0.30.0120.00616.97
8.0.20.0180.00417.40
8.0.10.0000.00716.91
8.0.00.0130.00916.85
7.4.330.0000.00515.09
7.4.320.0030.00316.43
7.4.300.0000.00616.51
7.4.290.0030.00316.52
7.4.280.0030.00316.59
7.4.270.0000.00716.45
7.4.260.0070.00016.50
7.4.250.0000.00816.45
7.4.240.0040.00416.54
7.4.230.0030.00316.49
7.4.220.0120.00916.53
7.4.210.0080.00616.57
7.4.200.0030.00316.70
7.4.190.0000.00716.67
7.4.160.0060.00916.51
7.4.150.0090.01517.40
7.4.140.0120.00817.86
7.4.130.0100.00916.48
7.4.120.0050.01216.59
7.4.110.0100.00716.39
7.4.100.0100.00716.55
7.4.90.0100.00616.56
7.4.80.0090.00919.39
7.4.70.0070.01016.64
7.4.60.0060.01016.53
7.4.50.0080.00016.48
7.4.40.0040.01422.77
7.4.30.0140.00316.42
7.4.00.0080.00814.93
7.3.330.0000.00513.32
7.3.320.0000.00713.33
7.3.310.0040.00416.20
7.3.300.0070.00016.25
7.3.290.0100.00616.28
7.3.280.0040.01216.30
7.3.270.0130.00317.40
7.3.260.0060.01116.47
7.3.250.0110.00916.40
7.3.240.0030.01316.46
7.3.230.0070.01316.57
7.3.210.0150.00316.57
7.3.200.0120.00919.39
7.3.190.0140.00716.36
7.3.180.0130.00616.40
7.3.170.0090.00916.46
7.3.160.0150.00016.44
7.3.120.0030.01014.79
7.2.330.0150.00416.82
7.2.320.0000.01916.44
7.2.310.0060.01316.64
7.2.300.0070.01016.37
7.2.290.0040.01216.68
7.2.60.0030.01216.95
7.2.00.0030.00619.47
7.1.200.0000.01215.35
7.1.100.0040.00818.09
7.1.70.0000.01016.98
7.1.60.0070.01619.82
7.1.50.0100.00316.62
7.1.00.0070.07322.31
7.0.200.0000.01116.52
7.0.140.0070.07021.97
7.0.60.0100.07019.96
7.0.50.0030.08317.85
7.0.40.0100.08020.11
7.0.30.0300.07020.30
7.0.20.0230.08320.25
7.0.10.0200.06020.24
7.0.00.0030.04320.23
5.6.280.0070.07321.16
5.6.210.0070.03720.63
5.6.200.0030.08318.29
5.6.190.0100.06720.63
5.6.180.0100.03720.42
5.6.170.0270.04720.51
5.6.160.0000.08020.61
5.6.150.0030.04718.23
5.6.140.0070.03718.24
5.6.130.0270.06318.13
5.6.120.0000.04321.13
5.6.110.0030.07021.10
5.6.100.0070.07021.00
5.6.90.0130.07721.04
5.6.80.0030.04320.54
5.6.70.0300.08020.42
5.5.350.0100.08020.42
5.5.340.0000.08318.08
5.5.330.0100.03720.27
5.5.320.0300.04020.27
5.5.310.0100.05020.26
5.5.300.0100.07717.93
5.5.290.0070.04717.94
5.5.280.0100.07020.78
5.5.270.0130.04320.88
5.5.260.0000.09320.96
5.5.250.0100.06320.59
5.5.240.0000.06320.07
5.4.450.0200.04019.55
5.4.440.0170.05719.41
5.4.430.0330.04319.54
5.4.420.0400.03319.16
5.4.410.0130.05018.92
5.4.400.0170.04318.74
5.4.390.0130.07018.65
5.4.380.0270.04318.79
5.4.370.0170.05318.83
5.4.360.0130.06318.59
5.4.350.0330.05018.78
5.4.340.0170.05318.72
5.4.320.0090.04112.51
5.4.310.0060.03812.51
5.4.300.0090.04012.51
5.4.290.0080.03712.51
5.4.280.0080.03712.40
5.4.270.0030.03812.38
5.4.260.0060.03812.37
5.4.250.0050.04212.38
5.4.240.0090.03212.38
5.4.230.0080.03512.36
5.4.220.0050.03712.36
5.4.210.0040.04612.37
5.4.200.0070.03612.37
5.4.190.0060.03612.36
5.4.180.0070.03612.36
5.4.170.0070.03612.37
5.4.160.0030.03912.36
5.4.150.0060.03712.36
5.4.140.0050.03812.04
5.4.130.0090.03512.03
5.4.120.0030.03811.98
5.4.110.0110.04111.98
5.4.100.0050.03611.99
5.4.90.0100.03411.98
5.4.80.0060.03911.99
5.4.70.0070.03411.98
5.4.60.0120.03911.98
5.4.50.0100.03811.98
5.4.40.0060.03411.97
5.4.30.0080.03411.96
5.4.20.0050.03611.96
5.4.10.0060.03411.97
5.4.00.0050.03711.46
5.3.290.0030.05212.80
5.3.280.0080.03812.71
5.3.270.0070.03712.73
5.3.260.0070.03912.71
5.3.250.0120.03212.71
5.3.240.0060.03812.72
5.3.230.0050.04012.71
5.3.220.0030.04212.68
5.3.210.0100.03712.68
5.3.200.0080.03612.68
5.3.190.0080.03612.68
5.3.180.0050.03812.67
5.3.170.0080.03612.67
5.3.160.0030.04112.67
5.3.150.0070.03812.67
5.3.140.0060.03712.66
5.3.130.0090.03912.66
5.3.120.0070.03712.66
5.3.110.0050.04012.66
5.3.100.0040.04112.12
5.3.90.0060.03612.09
5.3.80.0050.03812.07
5.3.70.0050.03912.07
5.3.60.0060.03612.07
5.3.50.0080.04212.01
5.3.40.0050.03912.02
5.3.30.0060.03511.98
5.3.20.0100.04611.76
5.3.10.0050.03811.72
5.3.00.0050.03911.71
5.2.170.0080.0329.21
5.2.160.0050.0429.21
5.2.150.0060.0319.21
5.2.140.0030.0329.21
5.2.130.0050.0289.17
5.2.120.0020.0319.16
5.2.110.0070.0279.17
5.2.100.0060.0279.18
5.2.90.0060.0289.16
5.2.80.0040.0319.16
5.2.70.0050.0309.16
5.2.60.0060.0309.11
5.2.50.0030.0339.09
5.2.40.0060.0279.06
5.2.30.0060.0299.04
5.2.20.0050.0329.03
5.2.10.0060.0278.94
5.2.00.0040.0308.80
5.1.60.0040.0258.08
5.1.50.0030.0268.08
5.1.40.0050.0248.07
5.1.30.0030.0288.42
5.1.20.0040.0288.44
5.1.10.0020.0298.16
5.1.00.0050.0298.16
5.0.50.0050.0196.63
5.0.40.0060.0186.48
5.0.30.0030.0326.30
5.0.20.0040.0196.27
5.0.10.0010.0226.25
5.0.00.0030.0316.24
4.4.90.0020.0164.78
4.4.80.0030.0154.75
4.4.70.0040.0194.76
4.4.60.0030.0154.76
4.4.50.0040.0144.77
4.4.40.0040.0234.71
4.4.30.0050.0174.76
4.4.20.0030.0154.84
4.4.10.0020.0164.85
4.4.00.0030.0254.76
4.3.110.0040.0144.67
4.3.100.0010.0164.66
4.3.90.0040.0134.64
4.3.80.0020.0254.58
4.3.70.0010.0164.63
4.3.60.0020.0154.63
4.3.50.0030.0154.63
4.3.40.0030.0234.54
4.3.30.0010.0173.29
4.3.20.0020.0163.26
4.3.10.0030.0143.23
4.3.00.0000.02015.07

preferences:
42.08 ms | 401 KiB | 5 Q