3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Foo { public function __construct(public array $foo = [1, 2, 3], public string $bar = 'baz') {} } var_dump(serialize(new Foo()));

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.5.20.0100.00920.11
8.5.10.0110.00716.66
8.5.00.0160.00619.97
8.4.170.0190.00621.92
8.4.160.0130.01023.84
8.4.150.0020.00114.05
8.4.140.0130.00817.71
8.4.130.0070.00517.59
8.4.120.0140.00522.28
8.4.110.0100.00718.77
8.4.100.0130.00617.98
8.4.90.0150.00617.97
8.4.80.0080.00517.71
8.4.70.0060.01117.72
8.4.60.0070.01018.72
8.4.50.0120.00718.65
8.4.40.0060.01317.59
8.4.30.0120.00920.47
8.4.20.0100.01019.82
8.4.10.0060.00319.43
8.3.300.0120.00820.23
8.3.290.0110.00920.66
8.3.280.0140.00518.31
8.3.270.0120.00816.49
8.3.260.0120.00516.36
8.3.250.0020.00618.95
8.3.240.0040.00616.56
8.3.230.0100.00916.50
8.3.220.0050.00217.14
8.3.210.0060.01316.63
8.3.200.0050.00416.54
8.3.190.0040.00417.36
8.3.180.0100.00916.71
8.3.170.0060.01219.17
8.3.160.0140.00317.24
8.3.150.0140.00417.13
8.3.140.0060.00316.72
8.3.130.0170.00316.54
8.3.120.0090.00020.74
8.3.110.0000.00820.94
8.3.100.0030.00624.06
8.3.90.0080.00026.77
8.3.80.0060.00318.31
8.3.70.0110.00416.58
8.3.60.0140.00716.80
8.3.50.0110.00718.41
8.3.40.0070.00722.00
8.3.30.0100.00320.04
8.3.20.0130.00623.53
8.3.10.0110.00723.48
8.3.00.0090.00920.71
8.2.300.0070.01322.28
8.2.290.0030.00620.53
8.2.280.0090.00718.17
8.2.270.0040.01517.15
8.2.260.0000.00818.34
8.2.250.0030.00518.41
8.2.240.0030.00618.84
8.2.230.0000.00922.58
8.2.220.0040.01137.54
8.2.210.0000.00826.77
8.2.200.0040.00416.38
8.2.190.0090.00618.54
8.2.180.0100.00316.63
8.2.170.0140.00718.89
8.2.160.0060.01022.96
8.2.150.0110.00720.83
8.2.140.0120.00622.09
8.2.130.0070.01122.11
8.2.120.0120.00620.95
8.2.110.0070.01120.98
8.2.100.0120.00620.75
8.2.90.0110.00720.48
8.2.80.0190.00020.95
8.2.70.0100.01020.45
8.2.60.0130.00620.36
8.2.50.0070.01120.82
8.2.40.0100.00620.61
8.2.30.0030.01720.29
8.2.20.0110.00420.27
8.2.10.0150.00620.23
8.2.00.0030.01320.46
8.1.340.0150.00517.55
8.1.330.0110.00818.31
8.1.320.0120.00716.16
8.1.310.0000.00718.52
8.1.300.0080.01220.17
8.1.290.0030.00630.84
8.1.280.0150.00025.92
8.1.270.0070.00723.97
8.1.260.0130.00723.79
8.1.250.0110.00423.82
8.1.240.0110.00320.27
8.1.230.0210.00020.15
8.1.220.0080.00820.55
8.1.210.0130.00920.11
8.1.200.0110.00420.40
8.1.190.0070.00720.33
8.1.180.0060.00920.21
8.1.170.0060.01620.47
8.1.160.0150.00420.18
8.1.150.0090.00620.47
8.1.140.0150.00020.09
8.1.130.0100.01020.39
8.1.120.0120.00920.34
8.1.110.0000.01420.25
8.1.100.0040.01420.29
8.1.90.0150.00020.24
8.1.80.0150.00321.47
8.1.70.0040.01120.21
8.1.60.0090.00620.58
8.1.50.0160.00320.33
8.1.40.0070.00720.54
8.1.30.0110.00420.66
8.1.20.0040.01421.78
8.1.10.0040.01120.38
8.1.00.0110.00320.11

preferences:
28.9 ms | 403 KiB | 5 Q