3v4l.org

run code in 300+ PHP versions simultaneously
<?php class TestClass() { public function baz() { echo "Worked!"; } } $foo = 'bam'; $bam = ['bar' => new TestClass()]; $$foo['bar']->baz(); function getResult() { return "string"; } echo getResult(){0};

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)
7.0.20.0300.06720.12
7.0.10.0000.08020.36
7.0.00.0130.06320.06
5.6.160.0070.03720.57
5.6.150.0030.05718.18
5.6.140.0000.06318.18
5.6.130.0000.05318.14
5.6.120.0170.07721.00
5.6.110.0100.06320.96
5.6.100.0130.03720.98
5.6.90.0070.07021.12
5.6.80.0030.07320.39
5.5.300.0100.08018.08
5.5.290.0130.07317.95
5.5.280.0030.07020.87
5.5.270.0030.05720.61
5.5.260.0130.05720.88
5.5.250.0270.06020.70
5.5.240.0330.05720.25

preferences:
141.3 ms | 1394 KiB | 7 Q