3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Foo { private $fooId; private $fooName; public void __set($name, $value) { $this->$name = $value; } public function __get($name) { if (self::__isset($name)) { return $this->$name; } $trace = debug_backtrace(); trigger_error( 'Undefined property via __get(): ' . $name . ' in ' . $trace[0]['file'] . ' on line ' . $trace[0]['line'], E_USER_NOTICE); return null; } public function __isset($name) { return isset($this->$name); } } $bar = new Foo(); $bar->fooId = 2; $bar->fooName = 'Name'; var_dump($bar);

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.4.140.4670.03716.34
5.4.130.4500.04016.16
5.4.120.4130.03016.46
5.4.110.4300.04316.32
5.4.100.4330.03016.53
5.4.90.2530.03716.48
5.4.80.0030.06316.46
5.4.70.3770.03716.43
5.4.60.3670.04016.43
5.4.50.4500.03316.19
5.4.40.4770.03316.52
5.4.30.4700.03716.45
5.4.20.4730.03716.32
5.4.10.4300.03716.23
5.4.00.3730.02715.70
5.3.240.4630.03714.60
5.3.230.3970.03314.66
5.3.220.3670.03714.61
5.3.210.3500.03314.62
5.3.200.3500.04014.71
5.3.190.0070.07014.47
5.3.180.0030.06014.48
5.3.170.3200.04014.61
5.3.160.3770.03314.48
5.3.150.2830.05314.59
5.3.140.4370.03714.64
5.3.130.4700.03314.57
5.3.120.4370.04014.56
5.3.110.4630.04014.58
5.3.100.3430.02314.04
5.3.90.3700.02714.05
5.3.80.4330.03714.06
5.3.70.3070.03713.90
5.3.60.0070.07314.04
5.3.50.0130.06313.95
5.3.40.3930.03313.98
5.3.30.3630.03713.79
5.3.20.3870.03313.73
5.3.10.4100.04013.66
5.3.00.3970.03313.55

preferences:
139.46 ms | 1394 KiB | 7 Q