3v4l.org

run code in 300+ PHP versions simultaneously
<?php trait TraitA { protected function doSomething(): string { return 'FOO'; } } trait TraitB { abstract protected function doSomething(): string; } class ParentClass { use TraitB; use TraitA; } class ChildClass extends ParentClass { public function __construct() { echo $this->doSomething(); } } $class = new ChildClass();

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.4.20.0040.00419.65
8.4.10.0060.00319.52
8.3.150.0080.00017.12
8.3.140.0130.00616.83
8.3.130.0000.00916.55
8.3.120.0050.00520.84
8.3.110.0030.00620.94
8.3.100.0080.00016.65
8.3.90.0080.00621.99
8.3.80.0180.00820.16
8.3.70.0260.00622.88
8.3.60.0260.00518.88
8.3.50.0170.00419.51
8.3.40.0180.00619.57
8.3.30.0150.01219.46
8.3.20.0230.00719.60
8.3.10.0210.00519.44
8.3.00.0190.00919.60
8.2.270.0150.00417.27
8.2.260.0120.00318.43
8.2.250.0060.00316.92
8.2.240.0060.00318.79
8.2.230.0080.00022.58
8.2.220.0060.00324.06
8.2.210.0110.00919.63
8.2.200.0140.00520.26
8.2.190.0170.00817.70
8.2.180.0150.01018.90
8.2.170.0230.00319.87
8.2.160.0240.00519.83
8.2.150.0220.00719.66
8.2.140.0260.00519.66
8.2.130.0240.00919.75
8.2.120.0270.00620.53
8.2.110.0310.00420.64
8.2.100.0240.00619.60
8.2.90.0250.00519.78
8.2.80.0210.00819.75
8.2.70.0180.00919.57
8.2.60.0210.00619.65
8.2.50.0240.00719.69
8.2.40.0240.00519.56
8.2.30.0210.00719.66
8.2.20.0180.00819.46
8.2.10.0160.00319.69
8.2.00.0170.00319.60
8.1.310.0070.01118.75
8.1.300.0150.00316.59
8.1.290.0190.00817.32
8.1.280.0160.00718.50
8.1.270.0210.00619.49
8.1.260.0190.00519.54
8.1.250.0160.00919.56
8.1.240.0160.00519.44
8.1.230.0130.00519.40
8.1.220.0140.00419.43
8.1.210.0160.00319.37
8.1.200.0120.00619.49
8.1.190.0150.00419.40
8.1.180.0120.00619.31
8.1.170.0150.00419.53
8.1.160.0110.00819.52
8.1.150.0170.00219.46
8.1.140.0160.00319.47
8.1.130.0170.00219.50
8.1.120.0150.00419.49
8.1.110.0170.00319.52
8.1.100.0150.00419.61
8.1.90.0160.00419.59
8.1.80.0180.00219.64
8.1.70.0160.00319.46
8.1.60.0140.00619.59
8.1.50.0170.00319.53
8.1.40.0180.00219.56
8.1.30.0180.00419.69
8.1.20.0170.00419.65
8.1.10.0210.00219.66
8.1.00.0180.00419.44

preferences:
61.57 ms | 403 KiB | 5 Q