3v4l.org

run code in 300+ PHP versions simultaneously
<?php function test($var) { echo "Test $var"; } class foo { var $arr = array("test"); /*function test($var) { echo "Test $var"; }*/ } class moo { static var $arr = array("test"); /*function test($var) { echo "Test $var"; }*/ } $a = new foo(); var_dump($a);; $a->arr[0]("testvalue"); moo::$arr[0]("another one"); ?>

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.0230.07720.07
7.0.10.0070.09320.33
7.0.00.0070.08320.06
5.6.170.0230.05320.41
5.6.160.0130.07720.71
5.6.150.0100.08318.19
5.6.140.0070.08318.18
5.6.130.0070.07318.29
5.6.120.0270.06720.97
5.6.110.0030.04321.12
5.6.100.0070.07020.97
5.6.90.0030.04020.98
5.6.80.0070.06020.39
5.5.310.0370.07720.51
5.5.300.0030.08017.97
5.5.290.0200.03317.95
5.5.280.0200.06720.89
5.5.270.0030.05320.76
5.5.260.0070.03720.84
5.5.250.0030.04320.50
5.5.240.0170.07720.21

preferences:
126.31 ms | 1398 KiB | 7 Q