3v4l.org

run code in 300+ PHP versions simultaneously
<?php class child implements Serializable { public function serialize() { return null; } public function unserialize($serialized) { } } class test { private $elems = []; public function add($something) { $this->elems[] = $something; } } $child = new child(); $t = new test(); $t->add(1); $t->add('test'); var_dump(unserialize(serialize($t))); $t->add($child); var_dump(unserialize(serialize($t))); $t->add($child); var_dump(unserialize(serialize($t)));

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.01518.43
8.3.50.0090.00617.98
8.3.40.0140.00718.66
8.3.30.0040.01118.84
8.3.20.0000.00721.75
8.3.10.0040.00420.38
8.3.00.0000.00819.38
8.2.180.0170.00325.92
8.2.170.0040.01122.96
8.2.160.0130.00619.46
8.2.150.0040.00424.18
8.2.140.0040.00424.66
8.2.130.0040.00419.33
8.2.120.0040.00426.35
8.2.110.0030.00620.10
8.2.100.0000.01117.97
8.2.90.0100.00017.75
8.2.80.0040.00818.04
8.2.70.0040.00417.46
8.2.60.0040.00417.63
8.2.50.0050.00318.10
8.2.40.0000.00821.04
8.2.30.0040.00419.23
8.2.20.0040.00418.18
8.2.10.0000.00719.45
8.2.00.0000.00718.13
8.1.280.0090.00625.92
8.1.270.0070.00322.10
8.1.260.0050.00326.35
8.1.250.0040.00428.09
8.1.240.0040.00822.09
8.1.230.0000.01120.82
8.1.220.0040.00417.78
8.1.210.0030.00618.77
8.1.200.0000.00917.36
8.1.190.0060.00317.35
8.1.180.0040.00418.10
8.1.170.0060.00318.59
8.1.160.0000.00718.85
8.1.150.0000.00718.76
8.1.140.0000.00720.17
8.1.130.0040.00417.45
8.1.120.0050.00217.45
8.1.110.0000.00717.41
8.1.100.0000.00917.30
8.1.90.0070.00417.40
8.1.80.0070.00417.38
8.1.70.0110.00217.38
8.1.60.0090.00517.46
8.1.50.0070.00717.41
8.1.40.0100.00617.40
8.1.30.0070.00717.60
8.1.20.0090.00617.54
8.1.10.0080.00617.47
8.1.00.0120.00217.37
8.0.300.0080.00019.54
8.0.290.0050.00316.88
8.0.280.0000.00718.36
8.0.270.0000.00716.87
8.0.260.0040.00416.80
8.0.250.0070.00016.94
8.0.240.0000.00616.97
8.0.230.0040.00917.00
8.0.220.0070.00516.89
8.0.210.0050.00716.89
8.0.200.0070.00616.95
8.0.190.0100.00216.94
8.0.180.0060.00716.88
8.0.170.0050.00816.92
8.0.160.0050.00616.88
8.0.150.0050.00716.83
8.0.140.0030.00816.89
8.0.130.0060.00415.06
8.0.120.0120.00016.83
8.0.110.0070.00616.94
8.0.100.0070.00516.87
8.0.90.0060.00716.85
8.0.80.0100.00716.89
8.0.70.0060.00516.85
8.0.60.0070.00516.88
8.0.50.0030.00916.91
8.0.30.0120.00816.99
8.0.20.0100.00817.00
8.0.10.0090.01016.93
8.0.00.0090.00816.91
7.4.330.0020.00215.55
7.4.320.0000.00616.61
7.4.300.0050.00216.52
7.4.290.0030.01016.48
7.4.280.0080.00516.60
7.4.270.0090.00216.57
7.4.260.0040.00816.45
7.4.250.0060.00616.46
7.4.240.0100.00216.52
7.4.230.0070.00516.48
7.4.220.0080.00316.57
7.4.210.0110.00416.56
7.4.200.0070.00416.46
7.4.190.0120.00316.49
7.4.180.0070.00716.47
7.4.160.0100.00916.54
7.4.150.0070.00816.47
7.4.140.0110.00817.11
7.4.130.0130.00316.59
7.4.120.0110.00816.43
7.4.110.0140.00616.50
7.4.100.0130.00516.57
7.4.90.0130.00516.47
7.4.80.0100.00817.41
7.4.70.0100.00716.42
7.4.60.0080.00816.45
7.4.50.0080.01116.38
7.4.40.0110.00616.45
7.4.30.0120.00616.45
7.4.20.0070.00716.44
7.4.10.0090.00616.50
7.4.00.0080.00816.00
7.3.330.0060.00514.74
7.3.320.0080.00314.71
7.3.310.0100.00216.19
7.3.300.0040.00816.25
7.3.290.0090.00116.29
7.3.280.0090.00916.22
7.3.270.0110.00516.19
7.3.260.0110.00816.34
7.3.250.0140.00316.12
7.3.240.0070.01116.37
7.3.230.0090.00916.22
7.3.220.0110.00716.15
7.3.210.0090.01016.23
7.3.200.0090.01016.33
7.3.190.0120.00916.29
7.3.180.0100.00716.27
7.3.170.0110.00616.25
7.3.160.0110.00616.23
7.3.150.0090.01016.32
7.3.140.0110.00616.22
7.3.130.0080.00816.27
7.3.120.0070.01015.98
7.3.110.0100.00915.89
7.3.100.0090.00915.92
7.3.90.0080.00815.84
7.3.80.0090.00815.81
7.3.70.0080.00715.82
7.3.60.0100.00615.79
7.3.50.0120.00415.78
7.3.40.0100.00715.84
7.3.30.0080.00815.84
7.3.20.0570.00815.90
7.3.10.0440.00815.84
7.3.00.0420.00915.83
7.2.340.0110.01316.30
7.2.330.0140.00816.45
7.2.320.0130.01116.36
7.2.310.0130.01016.37
7.2.300.0160.00716.47
7.2.290.0140.00816.46
7.2.280.0150.00616.40
7.2.270.0100.01116.38
7.2.260.0130.00816.44
7.2.250.0140.00616.16
7.2.240.0120.00916.24
7.2.230.0120.00616.25
7.2.220.0100.00916.06
7.2.210.0140.01116.04
7.2.200.0120.00916.07
7.2.190.0110.00716.04
7.2.180.0110.00716.09
7.2.170.0100.00816.02
7.2.160.0130.01016.13
7.2.150.0510.00816.14
7.2.140.0500.00916.16
7.2.130.0480.00816.19
7.2.120.0570.00616.20
7.2.110.0610.00916.25
7.2.100.0470.00816.20
7.2.90.0540.00716.15
7.2.80.0370.00816.16
7.2.70.0530.00716.18
7.2.60.0470.00616.18
7.2.50.0340.00916.22
7.2.40.0490.01016.21
7.2.30.0350.00916.19
7.2.20.0370.00816.14
7.2.10.0420.01016.19
7.2.00.0440.00616.15
7.1.330.0120.00815.92
7.1.320.0110.00915.57
7.1.310.0120.00815.71
7.1.300.0110.00915.59
7.1.290.0100.00915.60
7.1.280.0110.00615.76
7.1.270.0120.00815.66
7.1.260.0140.00715.65
7.1.250.0490.00715.03
7.1.240.0380.00815.22
7.1.230.0440.00715.31
7.1.220.0350.00815.33
7.1.210.0380.00915.30
7.1.200.0210.00815.31
7.1.190.0390.01015.29
7.1.180.0310.00915.27
7.1.170.0320.00815.20
7.1.160.0340.01015.37
7.1.150.0290.01115.40
7.1.140.0290.00715.37
7.1.130.0260.00915.29
7.1.120.0070.01115.32
7.1.110.0210.00715.33
7.1.100.0260.01115.29
7.1.90.0250.00415.29
7.1.80.0320.00715.40
7.1.70.0290.00815.34
7.1.60.0730.00615.32
7.1.50.0210.00815.38
7.1.40.0150.00815.33
7.1.30.0220.00815.35
7.1.20.0220.01015.34
7.1.10.0180.00715.39
7.1.00.0220.00815.30

preferences:
34.67 ms | 400 KiB | 5 Q