3v4l.org

run code in 300+ PHP versions simultaneously
<?php abstract class Animal{ abstract public function getSound(): string; } class Cat extends Animal{ public function getSound(): string{ return 'meow'; } } class Goldfish extends Animal{ public function getSound(): never { throw new Exception('Goldfish makes no sound'); } }

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.1.70.0080.00017.33
8.1.60.0030.00517.32
8.1.50.0000.00917.41
8.1.40.0060.00617.33
8.1.30.0100.00317.42
8.1.20.0070.00317.51
8.1.10.0090.00917.23
8.1.00.0180.00017.21
8.0.200.0020.01216.83
8.0.190.0090.00516.81
8.0.180.0100.00516.84
8.0.170.0110.00416.75
8.0.160.0110.00416.81
8.0.150.0090.00616.64
8.0.140.0120.00316.67
8.0.130.0080.00616.62
8.0.120.0110.00316.74
8.0.110.0140.00016.73
8.0.100.0120.00316.66
8.0.90.0120.00416.79
8.0.80.0070.00716.70
8.0.70.0000.01616.64
8.0.60.0070.00816.70
8.0.50.0090.00416.65
8.0.30.0070.00716.84
8.0.20.0120.00216.73
8.0.10.0120.00416.94
7.4.300.0100.00516.32
7.4.290.0170.00016.34
7.4.280.0180.00016.44
7.4.270.0130.00516.36
7.4.260.0160.00016.37
7.4.250.0150.00016.41
7.4.240.0120.00516.32
7.4.230.0170.00016.42
7.4.220.0150.00016.46
7.4.210.0100.00716.35
7.4.200.0070.00716.38
7.4.190.0050.00916.42
7.4.180.0090.00516.44
7.4.160.0090.00516.41
7.4.150.0100.00416.40
7.4.140.0090.00316.18
7.4.130.0140.00016.14
7.4.120.0110.00316.26
7.4.110.0090.00516.27
7.4.100.0130.00016.40
7.4.90.0050.00516.32
7.4.80.0090.00316.25
7.4.70.0110.00016.30
7.4.60.0090.00316.29
7.4.50.0140.00016.03
7.4.40.0050.00816.15
7.4.30.0040.00416.27
7.4.20.0070.00016.11
7.4.10.0000.00616.25
7.4.00.0030.00316.29

preferences:
140.43 ms | 1405 KiB | 7 Q