3v4l.org

run code in 300+ PHP versions simultaneously
<?php class test { public $inner = NULL; protected $prot = 1; private $priv = 2; } $one = new test; $two = new test; $one->inner = $two; $two->inner = $one; for($i = 100; $i > 0; $i--) { $serialized = preg_replace('/O:\d:"([^"]*)":/i', 'O:8:"stdClass":', serialize($one)); $storage = json_encode(unserialize(preg_replace_callback('/s:(\d+):"\x00([^"\x00]+)\x00([^"]+)"/i', function($matches) { return 's:'.($matches[1]-(strlen($matches[2])+2)).':"'.$matches[3].'"'; }, $serd))); }

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.54
8.3.50.0130.00821.40
8.3.40.0030.01319.09
8.3.30.0120.00319.04
8.3.20.0050.00320.25
8.3.10.0030.00623.39
8.3.00.0070.00317.88
8.2.180.0060.01017.00
8.2.170.0130.00322.96
8.2.160.0130.00320.52
8.2.150.0060.00324.18
8.2.140.0040.00424.66
8.2.130.0040.00426.16
8.2.120.0040.00422.20
8.2.110.0040.00822.38
8.2.100.0080.00417.88
8.2.90.0080.00019.08
8.2.80.0030.00617.97
8.2.70.0030.00617.88
8.2.60.0050.00317.93
8.2.50.0060.00318.07
8.2.40.0060.00320.01
8.2.30.0030.00618.04
8.2.20.0030.00518.00
8.2.10.0040.00418.09
8.2.00.0000.00817.92
8.1.280.0180.00325.92
8.1.270.0060.00622.11
8.1.260.0080.00026.35
8.1.250.0080.00028.09
8.1.240.0090.00023.91
8.1.230.0120.00017.48
8.1.220.0000.00817.74
8.1.210.0000.00918.77
8.1.200.0030.00617.36
8.1.190.0060.00317.35
8.1.180.0000.00918.10
8.1.170.0080.00018.69
8.1.160.0000.00821.96
8.1.150.0040.00418.93
8.1.140.0060.00317.64
8.1.130.0060.00317.86
8.1.120.0030.00517.55
8.1.110.0040.00417.64
8.1.100.0050.00317.65
8.1.90.0040.00417.59
8.1.80.0000.00817.53
8.1.70.0040.00417.63
8.1.60.0090.00017.74
8.1.50.0040.00417.70
8.1.40.0030.00617.57
8.1.30.0000.00917.69
8.1.20.0030.00517.80
8.1.10.0030.00517.55
8.1.00.0060.00317.69
8.0.300.0050.00318.77
8.0.290.0030.00616.75
8.0.280.0000.00718.46
8.0.270.0040.00417.27
8.0.260.0030.00317.13
8.0.250.0000.00817.12
8.0.240.0040.00417.12
8.0.230.0050.00317.12
8.0.220.0040.00417.07
8.0.210.0040.00417.11
8.0.200.0000.00717.01
8.0.190.0040.00417.19
8.0.180.0080.00017.16
8.0.170.0000.00817.11
8.0.160.0000.00817.13
8.0.150.0040.00417.14
8.0.140.0000.00917.13
8.0.130.0030.00313.54
8.0.120.0040.00417.07
8.0.110.0040.00416.95
8.0.100.0030.00516.90
8.0.90.0040.00417.00
8.0.80.0130.01017.16
8.0.70.0000.00816.96
8.0.60.0040.00417.02
8.0.50.0060.00317.11
8.0.30.0130.01117.33
8.0.20.0090.01517.46
8.0.10.0040.00417.24
8.0.00.0110.00816.94
7.4.330.0050.00015.00
7.4.320.0000.00616.74
7.4.300.0000.00616.61
7.4.290.0000.00816.71
7.4.280.0000.00816.86
7.4.270.0000.00716.67
7.4.260.0000.01216.70
7.4.250.0050.00316.79
7.4.240.0050.00316.69
7.4.230.0060.00316.64
7.4.220.0030.01616.91
7.4.210.0070.00716.83
7.4.200.0000.00816.85
7.4.160.0120.00616.92
7.4.150.0190.00817.40
7.4.140.0110.01317.86
7.4.130.0050.01516.76
7.4.120.0110.00816.80
7.4.110.0120.00916.96
7.4.100.0030.01616.61
7.4.90.0070.01116.81
7.4.80.0050.01519.39
7.4.70.0110.00816.80
7.4.60.0150.00316.83
7.4.50.0080.00016.71
7.4.40.0160.00316.87
7.4.30.0130.00316.76
7.4.00.0070.01015.08
7.3.330.0000.00513.46
7.3.320.0000.00513.47
7.3.310.0040.00416.45
7.3.300.0040.00416.46
7.3.290.0040.01116.55
7.3.280.0100.00816.54
7.3.270.0130.00717.40
7.3.260.0140.00616.55
7.3.250.0080.01116.66
7.3.240.0110.00916.55
7.3.230.0090.00916.59
7.3.210.0210.00016.57
7.3.200.0150.01219.39
7.3.190.0170.00816.58
7.3.180.0030.01516.35
7.3.170.0190.00316.49
7.3.160.0130.00716.51
7.3.120.0070.00715.01
7.3.110.0080.00814.99
7.3.100.0030.01015.00
7.3.90.0120.00414.98
7.3.80.0060.00315.20
7.3.70.0000.00915.05
7.3.60.0070.01015.03
7.3.50.0120.00615.11
7.3.40.0060.01014.87
7.3.30.0040.00815.09
7.3.20.0030.01016.70
7.3.10.0100.00716.61
7.3.00.0070.01116.81
7.2.330.0140.00516.80
7.2.320.0120.00616.95
7.2.310.0120.00616.79
7.2.300.0110.00916.78
7.2.290.0150.00416.82
7.2.240.0030.01015.19
7.2.230.0070.00715.36
7.2.220.0000.01815.31
7.2.210.0080.00815.25
7.2.200.0040.00715.21
7.2.190.0070.00314.88
7.2.180.0070.00715.14
7.2.170.0070.01015.18
7.2.160.0030.01315.27
7.2.150.0030.01317.04
7.2.140.0070.00717.03
7.2.130.0030.01017.16
7.2.120.0070.01017.14
7.2.110.0040.01117.02
7.2.100.0100.00717.15
7.2.90.0070.00717.25
7.2.80.0040.00717.03
7.2.70.0040.01116.80
7.2.60.0590.01117.01
7.2.50.0060.00917.04
7.2.40.0000.01516.89
7.2.30.0030.00916.84
7.2.20.0110.00817.02
7.2.10.0190.00016.84
7.2.00.0060.00617.12
7.1.330.0090.00416.08
7.1.320.0040.01215.90
7.1.310.0060.00316.14
7.1.300.0030.01016.13
7.1.290.0060.00916.01
7.1.280.0070.01016.00
7.1.270.0070.01016.15
7.1.260.0120.00316.08
7.1.250.0040.01116.08
7.1.200.0030.00915.84
7.1.100.0330.00717.79
7.1.70.0000.00817.09
7.1.60.0100.01619.32
7.1.50.0070.01117.27
7.1.00.0030.07722.27
7.0.200.0040.00416.95
7.0.140.0100.06722.14
7.0.90.0370.08019.96
7.0.80.0600.07719.85
7.0.70.0470.08719.89
7.0.60.0030.08319.88
7.0.50.0100.07720.25
7.0.40.0070.08720.05
7.0.30.0130.08320.00
7.0.20.0100.07320.10
7.0.10.0030.08319.99
7.0.00.0030.07020.10
5.6.280.0070.06721.10
5.6.240.0100.07320.64
5.6.230.0030.09320.57
5.6.220.0070.08720.50
5.6.210.0170.07020.57
5.6.200.0070.08721.09
5.6.190.0030.08321.08
5.6.180.0100.05021.09
5.6.170.0170.07321.02
5.6.160.0100.07321.14
5.6.150.0030.05021.07
5.6.140.0070.08321.00
5.6.130.0070.08721.06
5.6.120.0070.04321.02
5.6.110.0070.08321.05
5.6.100.0000.06320.95
5.6.90.0070.09720.94
5.6.80.0100.04720.48
5.6.70.0130.08020.46
5.6.60.0170.06720.54
5.6.50.0030.07020.39
5.6.40.0030.08020.27
5.6.30.0070.09020.54
5.6.20.0070.05020.43
5.6.10.0170.06720.38
5.6.00.0070.04720.40
5.5.380.0100.03720.45
5.5.370.0100.05020.37
5.5.360.0070.07720.35
5.5.350.0070.05020.39
5.5.340.0030.08020.80
5.5.330.0100.08320.81
5.5.320.0030.07320.91
5.5.310.0070.08720.86
5.5.300.0030.05320.80
5.5.290.0130.09320.84
5.5.280.0070.04020.89
5.5.270.0030.09020.82
5.5.260.0070.08720.92
5.5.250.0070.07720.70
5.5.240.0100.07720.32
5.5.230.0130.05020.21
5.5.220.0000.05020.28
5.5.210.0070.05720.21
5.5.200.0000.06020.28
5.5.190.0200.07720.29
5.5.180.0000.08720.13
5.5.160.0100.08320.14
5.5.150.0130.07720.27
5.5.140.0100.07320.08
5.5.130.0100.07020.21
5.5.120.0070.07019.99
5.5.110.0000.09320.17
5.5.100.0070.07720.11
5.5.90.0130.03720.08
5.5.80.0030.05020.13
5.5.70.0070.04320.14
5.5.60.0070.08020.10
5.5.50.0130.06319.92
5.5.40.0130.08020.00
5.5.30.0200.06320.12
5.5.20.0030.09020.08
5.5.10.0270.06020.02
5.5.00.0100.07719.97
5.4.450.0070.08319.38
5.4.440.0000.04719.54
5.4.430.0130.07019.22
5.4.420.0100.07019.50
5.4.410.0070.05019.32
5.4.400.0100.07319.05
5.4.390.0130.06718.91
5.4.380.0100.07019.18
5.4.370.0000.07319.16
5.4.360.0070.07018.91
5.4.350.0130.06719.16
5.4.340.0030.06019.23
5.4.320.0100.04319.05
5.4.310.0070.08319.10
5.4.300.0030.04718.84
5.4.290.0070.08319.02
5.4.280.0100.05019.04
5.4.270.0100.07719.14
5.4.260.0200.06319.13
5.4.250.0000.08718.84
5.4.240.0170.05019.20
5.4.230.0070.06319.17
5.4.220.0170.07319.11
5.4.210.0070.09018.84
5.4.200.0070.07719.14
5.4.190.0130.07318.84
5.4.180.0130.07319.03
5.4.170.0030.05019.14
5.4.160.0100.07719.05
5.4.150.0100.04719.10
5.4.140.0070.08316.46
5.4.130.0030.07716.46
5.4.120.0070.06716.41
5.4.110.0100.07316.30
5.4.100.0130.07016.49
5.4.90.0000.08016.54
5.4.80.0030.07316.40
5.4.70.0130.05716.45
5.4.60.0100.03316.39
5.4.50.0100.06316.40
5.4.40.0100.06316.53
5.4.30.0130.06016.29
5.4.20.0100.03716.46
5.4.10.0100.06716.24
5.4.00.0000.05315.73
5.3.290.0030.08314.65
5.3.280.0030.06014.66
5.3.270.0170.06714.67
5.3.260.0100.04314.61
5.3.250.0130.06714.70
5.3.240.0000.05314.72
5.3.230.0070.06714.63
5.3.220.0130.06714.68
5.3.210.0070.04314.69
5.3.200.0030.08014.63
5.3.190.0100.06314.71
5.3.180.0000.08714.62
5.3.170.0070.07314.58
5.3.160.0000.06714.63
5.3.150.0030.07714.68
5.3.140.0070.04014.55
5.3.130.0130.07014.62
5.3.120.0070.06014.58
5.3.110.0070.08014.52
5.3.100.0070.07013.99
5.3.90.0030.08014.01
5.3.80.0070.05714.13
5.3.70.0070.06314.13
5.3.60.0030.04714.09
5.3.50.0100.07713.93
5.3.40.0100.07313.98
5.3.30.0070.05313.93
5.3.20.0070.06713.71
5.3.10.0170.06013.68
5.3.00.0030.05313.70
5.2.170.0000.05311.13
5.2.160.0100.05711.21
5.2.150.0000.06011.05
5.2.140.0100.06011.14
5.2.130.0030.06311.11
5.2.120.0130.03311.09
5.2.110.0070.05711.21
5.2.100.0030.06311.09
5.2.90.0070.03310.98
5.2.80.0130.05311.00
5.2.70.0000.06711.08
5.2.60.0100.04011.14
5.2.50.0070.03711.11
5.2.40.0030.06311.04
5.2.30.0170.04011.00
5.2.20.0070.04710.82
5.2.10.0000.06310.95
5.2.00.0100.05310.63
5.1.60.0070.0539.84
5.1.50.0030.05010.07
5.1.40.0100.0409.86
5.1.30.0030.05010.39
5.1.20.0100.05010.42
5.1.10.0070.05010.19
5.1.00.0070.05010.06
5.0.50.0000.0338.62
5.0.40.0070.0338.40
5.0.30.0000.0638.34
5.0.20.0000.0238.04
5.0.10.0000.0438.29
5.0.00.0030.0478.02
4.4.90.0070.0277.20
4.4.80.0070.0137.20
4.4.70.0070.0277.20
4.4.60.0070.0207.20
4.4.50.0030.0377.20
4.4.40.0000.0537.20
4.4.30.0030.0377.20
4.4.20.0000.0377.20
4.4.10.0030.0377.20
4.4.00.0070.0537.20
4.3.110.0030.0337.20
4.3.100.0070.0307.20
4.3.90.0070.0307.20
4.3.80.0030.0407.20
4.3.70.0100.0177.20
4.3.60.0000.0277.20
4.3.50.0030.0177.20
4.3.40.0030.0307.20
4.3.30.0030.0337.20
4.3.20.0030.0277.20
4.3.10.0030.0377.20
4.3.00.0000.0407.20

preferences:
32.83 ms | 401 KiB | 5 Q