3v4l.org

run code in 300+ PHP versions simultaneously
<?php class ApiKey { public string $apiKey = 'abc123'; public function set(string $newKey): void { $this->apiKey = $newKey; } public function get(): string { return $this->apiKey; } } $config = new ApiKey(); var_dump($config->get()); $config->set('asdfasdf'); var_dump($config->get());

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.10.0080.01020.17
8.5.00.0130.00820.16
8.4.150.0020.00114.05
8.4.140.0130.00917.77
8.4.130.0050.00617.72
8.4.120.0090.01024.43
8.4.110.0060.00422.59
8.4.100.0110.00818.83
8.4.90.0130.00819.02
8.4.80.0110.00918.85
8.4.70.0110.00717.94
8.4.60.0100.01019.15
8.4.50.0110.00918.55
8.4.40.0110.00719.55
8.4.30.0040.01518.80
8.4.20.0080.01219.39
8.4.10.0090.00023.71
8.3.280.0130.00918.45
8.3.270.0090.01016.76
8.3.260.0130.00516.41
8.3.250.0130.00619.03
8.3.240.0060.00217.22
8.3.230.0110.00816.60
8.3.220.0090.00718.86
8.3.210.0140.00516.66
8.3.200.0070.00116.73
8.3.190.0110.00716.96
8.3.180.0140.00417.18
8.3.170.0110.00720.36
8.3.160.0150.00317.09
8.3.150.0110.00717.31
8.3.140.0070.00718.28
8.3.130.0030.00618.61
8.3.120.0060.00320.95
8.3.110.0000.00820.94
8.3.100.0000.00924.06
8.3.90.0030.00526.77
8.3.80.0030.00617.97
8.3.70.0150.00418.24
8.3.60.0150.00018.41
8.3.50.0120.00316.32
8.3.40.0160.00620.19
8.3.30.0100.00318.85
8.3.20.0070.00724.18
8.3.10.0040.00424.66
8.3.00.0080.00026.16
8.2.290.0140.00520.68
8.2.280.0060.00818.65
8.2.270.0120.00617.05
8.2.260.0060.01216.54
8.2.250.0090.00318.56
8.2.240.0030.00618.99
8.2.230.0040.00422.58
8.2.220.0070.00337.54
8.2.210.0100.00726.77
8.2.200.0110.00016.63
8.2.190.0140.00016.58
8.2.180.0070.01418.29
8.2.170.0040.01818.76
8.2.160.0100.00722.96
8.2.150.0020.00525.66
8.2.140.0140.00024.66
8.2.130.0070.00026.16
8.2.120.0000.00826.16
8.2.110.0070.00319.45
8.2.100.0040.00717.78
8.2.90.0060.00319.64
8.2.80.0060.00319.34
8.2.70.0050.00317.63
8.2.60.0000.00818.05
8.2.50.0040.00418.07
8.2.40.0030.00618.03
8.2.30.0060.00318.00
8.2.20.0040.00419.19
8.2.10.0040.00417.73
8.2.00.0000.00817.62
8.1.330.0120.00521.89
8.1.320.0100.00816.33
8.1.310.0000.00918.32
8.1.300.0110.00416.10
8.1.290.0070.00330.84
8.1.280.0000.01525.92
8.1.270.0040.00424.66
8.1.260.0070.00026.35
8.1.250.0050.00328.09
8.1.240.0030.00622.61
8.1.230.0040.00721.04
8.1.220.0000.00817.74
8.1.210.0050.00318.77
8.1.200.0000.00817.35
8.1.190.0050.00317.41
8.1.180.0000.00818.10
8.1.170.0050.00318.82
8.1.160.0070.00018.82
8.1.150.0000.00718.50
8.1.140.0060.00317.33
8.1.130.0070.00017.41
8.1.120.0040.00417.39
8.1.110.0000.00717.43
8.1.100.0000.00817.38
8.1.90.0030.00517.39
8.1.80.0040.00417.39
8.1.70.0050.00217.50
8.1.60.0040.00417.61
8.1.50.0000.00817.65
8.1.40.0000.00917.73
8.1.30.0040.00417.65
8.1.20.0040.00417.57
8.1.10.0030.00517.50
8.1.00.0040.00417.54
8.0.300.0040.00419.89
8.0.290.0050.00516.75
8.0.280.0070.00018.27
8.0.270.0070.00016.77
8.0.260.0000.00716.77
8.0.250.0000.00816.91
8.0.240.0070.00016.90
8.0.230.0030.00316.86
8.0.220.0000.00716.78
8.0.210.0080.00016.74
8.0.200.0000.00716.79
8.0.190.0070.00016.83
8.0.180.0040.00416.81
8.0.170.0000.00716.71
8.0.160.0050.00216.75
8.0.150.0000.00816.76
8.0.140.0000.00716.64
8.0.130.0000.00716.76
8.0.120.0030.00316.67
8.0.110.0000.00716.63
8.0.100.0040.00416.77
8.0.90.0060.00316.68
8.0.80.0040.00416.75
8.0.70.0050.00316.75
8.0.60.0070.00016.75
8.0.50.0000.00716.77
8.0.30.0000.00716.76
8.0.20.0030.00316.82
8.0.10.0000.00716.88

preferences:
125.75 ms | 403 KiB | 5 Q