3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Bar { private $msg; public function test($msg) { $this->msg = $msg; } public function shout() { echo $this->msg; } } class Foo { private $bar; public function __construct($bar) { $this->bar = $bar; } public function say($msg) { $bar = $this->bar; $bar->test($msg); $this->bar->shout(); } } $test_me = new Foo(new Bar); $test_me->say('ha ha');

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.10.0130.00723.57
8.3.140.0060.00920.64
8.3.130.0100.00016.52
8.3.120.0090.00020.77
8.3.110.0000.01016.53
8.3.100.0100.00018.30
8.3.90.0000.00826.77
8.3.80.0060.00617.97
8.3.70.0110.00718.15
8.3.60.0150.00016.59
8.3.50.0120.00318.31
8.3.40.0030.01020.52
8.3.30.0210.00018.67
8.3.20.0040.00424.18
8.3.10.0050.00224.66
8.3.00.0020.00526.16
8.2.260.0090.00916.50
8.2.250.0130.00618.57
8.2.240.0050.00518.86
8.2.230.0100.00020.94
8.2.220.0070.00337.54
8.2.210.0080.00026.77
8.2.200.0090.00018.41
8.2.190.0040.01916.58
8.2.180.0060.00918.38
8.2.170.0070.00718.96
8.2.160.0040.01122.96
8.2.150.0080.00025.66
8.2.140.0080.00624.66
8.2.130.0040.01126.16
8.2.120.0030.00620.63
8.2.110.0000.00921.12
8.2.100.0040.00717.78
8.2.90.0000.00818.22
8.2.80.0080.00018.03
8.2.70.0080.00017.47
8.2.60.0000.00817.63
8.2.50.0050.00317.55
8.2.40.0070.00018.22
8.2.30.0080.00018.04
8.2.20.0000.00719.25
8.2.10.0110.00817.66
8.2.00.0120.00317.52
8.1.300.0060.01316.19
8.1.290.0070.00330.84
8.1.280.0150.00025.92
8.1.270.0050.00324.66
8.1.260.0040.00426.35
8.1.250.0000.00828.09
8.1.240.0120.00020.68
8.1.230.0110.00020.91
8.1.220.0040.00417.74
8.1.210.0000.00818.77
8.1.200.0040.00417.13
8.1.190.0050.00517.23
8.1.180.0000.00918.10
8.1.170.0000.00818.62
8.1.160.0040.00418.77
8.1.150.0000.00718.53
8.1.140.0110.00417.25
8.1.130.0100.00517.29
8.1.120.0120.00417.48
8.1.110.0050.01017.44
8.1.100.0110.00417.45
8.1.90.0000.01517.54
8.1.80.0160.00017.45
8.1.70.0130.00017.44
8.1.60.0110.00517.62
8.1.50.0100.00617.57
8.1.40.0140.00517.59
8.1.30.0110.00517.62
8.1.20.0130.00317.68
8.1.10.0140.00317.63
8.1.00.0130.00317.52
8.0.300.0060.00320.02
8.0.290.0060.00316.58
8.0.280.0040.00418.44
8.0.270.0100.00316.82
8.0.260.0070.00716.75
8.0.250.0110.00416.93
8.0.240.0120.00316.84
8.0.230.0100.00516.68
8.0.220.0140.00016.62
8.0.210.0070.00716.74
8.0.200.0090.00616.85
8.0.190.0060.00616.84
8.0.180.0110.00316.86
8.0.170.0110.00316.86
8.0.160.0120.00216.86
8.0.150.0090.00516.73
8.0.140.0150.00016.65
8.0.130.0120.00316.64
8.0.120.0100.00016.73
8.0.110.0090.00616.66
8.0.100.0150.00416.67
8.0.90.0100.00516.62
8.0.80.0150.00016.83
8.0.70.0110.00216.65
8.0.60.0070.01016.62
8.0.50.0140.00216.73
8.0.30.0110.00616.65
8.0.20.0160.00016.87
8.0.10.0130.00316.80

preferences:
46.82 ms | 403 KiB | 5 Q