3v4l.org

run code in 300+ PHP versions simultaneously
<?php class SetOnce { private $value; public function __construct($value) { $this->value = $value; } public function getValue() { return $this->value; } } class Foo { proteced $bar; function __construct($val) { $this->bar = new SetOnce($val * 2); } function getBar() { return $bar->getValue(); } }

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)
5.6.160.0030.04320.46
5.6.150.0070.05018.17
5.6.140.0030.08318.24
5.6.130.0030.05018.21
5.6.120.0130.06021.16
5.6.110.0070.09021.02
5.6.100.0100.05020.98
5.6.90.0070.06021.04
5.6.80.0130.07720.36
5.5.300.0070.06017.99
5.5.290.0070.07718.07
5.5.280.0070.08720.96
5.5.270.0130.08020.85
5.5.260.0030.08320.65
5.5.250.0130.08020.71
5.5.240.0200.07020.36

preferences:
139.08 ms | 993 KiB | 7 Q