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.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.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.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:
50.53 ms | 400 KiB | 5 Q