3v4l.org

run code in 300+ PHP versions simultaneously
<?php class A { private $b = 'foo'; } class B extends A { public function __sleep() { return array('b'); } } class C extends A implements Serializable { public function unserialize($serialized) { /*... */ } public function serialize() { $b = new ReflectionProperty('A', 'b'); $b->setAccessible(true); return serialize(array('b' => $b->getValue($this))); } } var_dump(serialize(new A())); var_dump(serialize(new B())); var_dump(serialize(new C())); var_dump((array) new C());

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.0040.01118.65
8.3.50.0090.00921.99
8.3.40.0150.00018.73
8.3.30.0060.00918.71
8.3.20.0040.00418.52
8.3.10.0030.00520.91
8.3.00.0040.00723.41
8.2.180.0030.01716.63
8.2.170.0140.00722.96
8.2.160.0140.00020.44
8.2.150.0040.00424.18
8.2.140.0120.00324.66
8.2.130.0040.00426.16
8.2.120.0040.00421.06
8.2.110.0030.00720.46
8.2.100.0110.00018.03
8.2.90.0030.00617.97
8.2.80.0000.00917.97
8.2.70.0030.00617.50
8.2.60.0040.00418.04
8.2.50.0040.00418.07
8.2.40.0000.00918.16
8.2.30.0040.00419.79
8.2.20.0040.00417.68
8.2.10.0080.00017.75
8.2.00.0040.00417.81
8.1.280.0120.00625.92
8.1.270.0070.00023.99
8.1.260.0070.00726.35
8.1.250.0000.00828.09
8.1.240.0050.00520.75
8.1.230.0000.01220.96
8.1.220.0030.00617.76
8.1.210.0060.00318.88
8.1.200.0030.00617.48
8.1.190.0040.00417.53
8.1.180.0040.00418.10
8.1.170.0030.00618.52
8.1.160.0040.00418.91
8.1.150.0070.00018.77
8.1.140.0040.00417.37
8.1.130.0030.00317.84
8.1.120.0000.00717.35
8.1.110.0030.00517.46
8.1.100.0000.00817.54
8.1.90.0040.00417.38
8.1.80.0040.00417.31
8.1.70.0000.00817.40
8.1.60.0040.00417.49
8.1.50.0040.00417.38
8.1.40.0040.00417.55
8.1.30.0040.00417.64
8.1.20.0000.00817.69
8.1.10.0000.00717.57
8.1.00.0040.00417.46
8.0.300.0000.00719.90
8.0.290.0000.00916.75
8.0.280.0030.00318.47
8.0.270.0050.00217.18
8.0.260.0000.00716.95
8.0.250.0070.00017.01
8.0.240.0030.00617.06
8.0.230.0030.00317.02
8.0.220.0030.00316.97
8.0.210.0000.00816.96
8.0.200.0000.00617.02
8.0.190.0070.00017.01
8.0.180.0030.00717.00
8.0.170.0030.00617.06
8.0.160.0030.00416.94
8.0.150.0000.00916.98
8.0.140.0030.00316.92
8.0.130.0060.00013.37
8.0.120.0030.00316.80
8.0.110.0040.00416.89
8.0.100.0080.00017.00
8.0.90.0000.00716.99
8.0.80.0030.01716.86
8.0.70.0040.00417.04
8.0.60.0000.00817.09
8.0.50.0030.00616.84
8.0.30.0100.00816.96
8.0.20.0080.01217.40
8.0.10.0040.00416.88
8.0.00.0140.00516.89
7.4.330.0000.00514.73
7.4.320.0040.00416.54
7.4.300.0000.00616.57
7.4.290.0000.00716.61
7.4.280.0090.00316.37
7.4.270.0030.00316.64
7.4.260.0000.00613.34
7.4.250.0040.00416.52
7.4.240.0070.00016.60
7.4.230.0030.00316.41
7.4.220.0090.00916.63
7.4.210.0060.01016.54
7.4.200.0000.00716.52
7.4.190.0000.00716.69
7.4.160.0100.00616.59
7.4.150.0110.00617.40
7.4.140.0080.01017.86
7.4.130.0100.00716.47
7.4.120.0090.00916.60
7.4.110.0040.01316.50
7.4.100.0130.00616.54
7.4.90.0060.01216.75
7.4.80.0070.01119.37
7.4.70.0060.00916.62
7.4.60.0080.00816.59
7.4.50.0030.00616.65
7.4.40.0050.00522.27
7.4.30.0040.01716.76
7.4.00.0050.01114.99
7.3.330.0000.00513.21
7.3.320.0030.00313.39
7.3.310.0070.00016.41
7.3.300.0070.00016.30
7.3.290.0160.00316.37
7.3.280.0120.00716.42
7.3.270.0070.01017.40
7.3.260.0090.01018.24
7.3.250.0100.01416.47
7.3.240.0140.00316.51
7.3.230.0150.00416.40
7.3.210.0120.00616.50
7.3.200.0090.01319.39
7.3.190.0070.01016.50
7.3.180.0060.01116.50
7.3.170.0080.00816.42
7.3.160.0130.00316.40
7.3.120.0080.01014.90
7.3.110.0120.00614.81
7.3.100.0070.00714.67
7.3.90.0040.00814.71
7.3.80.0040.00414.80
7.3.70.0110.00314.77
7.3.60.0070.00714.67
7.3.50.0000.01314.79
7.3.40.0060.00914.84
7.3.30.0040.01214.50
7.3.20.0060.00316.66
7.3.10.0060.00616.68
7.3.00.0070.00716.63
7.2.330.0090.00816.36
7.2.320.0030.01516.70
7.2.310.0090.01316.46
7.2.300.0100.00616.48
7.2.290.0110.00616.64
7.2.250.0130.00615.06
7.2.240.0140.00714.91
7.2.230.0100.00714.89
7.2.220.0060.00314.79
7.2.210.0000.01415.04
7.2.200.0040.00715.09
7.2.190.0050.00515.04
7.2.180.0040.01114.79
7.2.170.0120.00614.85
7.2.00.0060.00619.12
7.1.330.0000.01415.75
7.1.320.0000.01115.80
7.1.310.0000.01015.71
7.1.300.0030.00915.65
7.1.290.0040.01115.52
7.1.280.0090.00915.72
7.1.270.0000.01115.42
7.1.260.0000.01215.61
7.1.100.0030.01018.16
7.1.70.0000.01017.02
7.1.60.0030.02219.40
7.1.50.0100.01016.74
7.1.00.0000.07022.37
7.0.200.0040.00416.67
7.0.140.0000.07722.21
7.0.60.0030.08021.88
7.0.50.0030.08022.11
7.0.40.0070.08020.11
7.0.30.0100.07020.19
7.0.20.0070.08020.04
7.0.10.0000.09020.11
7.0.00.0100.08020.05
5.6.280.0030.07321.00
5.6.210.0100.07320.70
5.6.200.0100.06721.05
5.6.190.0100.08320.97
5.6.180.0030.05021.15
5.6.170.0100.07021.00
5.6.160.0070.08021.06
5.6.150.0030.08021.13
5.6.140.0000.08321.01
5.6.130.0130.05321.01
5.6.120.0030.07721.11
5.6.110.0100.07720.98
5.6.100.0100.05321.05
5.6.90.0070.07721.00
5.6.80.0070.07320.45
5.6.70.0000.08020.50
5.6.60.0030.08020.37
5.6.50.0030.06320.48
5.6.40.0100.07020.33
5.6.30.0030.07020.51
5.6.20.0130.07320.26
5.6.10.0100.06020.36
5.6.00.0030.08320.34
5.5.350.0100.07720.44
5.5.340.0030.07720.87
5.5.330.0030.07020.88
5.5.320.0070.06020.89
5.5.310.0070.06320.78
5.5.300.0000.05020.81
5.5.290.0030.07720.98
5.5.280.0130.08020.88
5.5.270.0070.08020.90
5.5.260.0000.09320.98
5.5.250.0130.06320.69
5.5.240.0030.08020.26
5.5.230.0100.08020.07
5.5.220.0070.06320.22
5.5.210.0070.07720.15
5.5.200.0030.08020.04
5.5.190.0100.07320.23
5.5.180.0070.08020.29
5.5.160.0100.07320.22
5.5.150.0100.07720.20
5.5.140.0000.07720.23
5.5.130.0130.05320.04
5.5.120.0070.08020.12
5.5.110.0000.08020.15
5.5.100.0100.07020.13
5.5.90.0030.07720.19
5.5.80.0070.07720.09
5.5.70.0130.06320.05
5.5.60.0100.07020.04
5.5.50.0070.07320.00
5.5.40.0070.07720.20
5.5.30.0030.08019.88
5.5.20.0030.07319.88
5.5.10.0100.07020.07
5.5.00.0070.07020.14
5.4.450.0070.07019.23
5.4.440.0170.07019.40
5.4.430.0000.07319.33
5.4.420.0070.06719.39
5.4.410.0030.07719.10
5.4.400.0000.07719.07
5.4.390.0000.07319.17
5.4.380.0070.06718.92
5.4.370.0030.07319.01
5.4.360.0070.04719.16
5.4.350.0100.07019.04
5.4.340.0070.06719.07
5.4.320.0070.08019.07
5.4.310.0000.06019.01
5.4.300.0030.07319.01
5.4.290.0070.06718.92
5.4.280.0000.08319.01
5.4.270.0030.07018.90
5.4.260.0030.08318.91
5.4.250.0070.07019.06
5.4.240.0070.06019.07
5.4.230.0100.05719.00
5.4.220.0030.07719.00
5.4.210.0100.07019.02
5.4.200.0070.07719.07
5.4.190.0100.06319.00
5.4.180.0070.07319.20
5.4.170.0070.07318.89
5.4.160.0070.06719.21
5.4.150.0070.07019.10
5.4.140.0030.07716.49
5.4.130.0100.06316.50
5.4.120.0030.06316.31
5.4.110.0070.07716.39
5.4.100.0070.06016.43
5.4.90.0000.07316.52
5.4.80.0000.07016.41
5.4.70.0030.06316.35
5.4.60.0070.07016.48
5.4.50.0130.06016.32
5.4.40.0070.07016.46
5.4.30.0100.06016.30
5.4.20.0000.05716.43
5.4.10.0070.07016.40
5.4.00.0030.05715.79
5.3.290.0000.07714.73
5.3.280.0030.07714.47
5.3.270.0000.08014.66
5.3.260.0000.07714.65
5.3.250.0030.07714.63
5.3.240.0000.06714.47
5.3.230.0030.07714.63
5.3.220.0030.04714.62
5.3.210.0100.06014.64
5.3.200.0070.07314.43
5.3.190.0030.07014.65
5.3.180.0070.05714.54
5.3.170.0100.06714.62
5.3.160.0000.06314.61
5.3.150.0070.05014.67
5.3.140.0000.08014.62
5.3.130.0070.08014.56
5.3.120.0030.07714.66
5.3.110.0030.08014.60
5.3.100.0030.06714.10
5.3.90.0030.04714.04
5.3.80.0030.07014.00
5.3.70.0030.07014.03
5.3.60.0030.07714.07
5.3.50.0030.06713.91
5.3.40.0000.07714.05
5.3.30.0000.07713.81
5.3.20.0030.07313.66
5.3.10.0030.06713.71
5.3.00.0030.07313.68
5.2.170.0000.05311.20
5.2.160.0030.06711.24
5.2.150.0030.05711.21
5.2.140.0070.06011.05
5.2.130.0070.05711.10
5.2.120.0030.06011.16
5.2.110.0000.05711.21
5.2.100.0030.06311.16
5.2.90.0070.05311.11
5.2.80.0030.06011.11
5.2.70.0030.05011.17
5.2.60.0030.05311.07
5.2.50.0030.06011.11
5.2.40.0100.05011.04
5.2.30.0000.06310.82
5.2.20.0030.06310.96
5.2.10.0030.05710.95
5.2.00.0000.06010.53
5.1.60.0030.0539.98
5.1.50.0000.05710.04
5.1.40.0030.05010.04
5.1.30.0000.06010.35
5.1.20.0100.04310.38
5.1.10.0070.0509.96
5.1.00.0000.06010.09
5.0.50.0000.0509.02
5.0.40.0070.0339.02
5.0.30.0030.0639.02
5.0.20.0030.0409.02
5.0.10.0000.0479.02
5.0.00.0030.0639.02
4.4.90.0070.0309.02
4.4.80.0000.0309.02
4.4.70.0100.0279.02
4.4.60.0100.0279.02
4.4.50.0030.0309.02
4.4.40.0030.0509.02
4.4.30.0000.0339.02
4.4.20.0000.0339.02
4.4.10.0000.0239.02
4.4.00.0000.0579.02
4.3.110.0070.0309.02
4.3.100.0000.0379.02
4.3.90.0000.0339.02
4.3.80.0030.0409.02
4.3.70.0030.0339.02
4.3.60.0000.0279.02
4.3.50.0000.0339.02
4.3.40.0030.0439.02
4.3.30.0000.0309.02
4.3.20.0000.0379.02
4.3.10.0030.0339.02
4.3.00.0030.0339.02

preferences:
57.67 ms | 401 KiB | 5 Q