3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $search = htmlentities('testapple'); if (strpos($search, 'apple') !== false){ echo '\e[31mRED TEXT\e[m'; echo preg_replace("/".$search."/", $search." <img src='".$search.".png'>", "apple"); }else echo "ELSE"; ?>
based on OETh2

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).
Note: hhvm uses a JIT which only kicks in after a few runs. Since we run scripts only once, hhvm always runs slower.

VersionSystem time (s)User time (s)Memory (MiB)
7.2.60.0100.00316.89
7.2.00.0060.00919.68
7.1.200.0000.00915.89
7.1.100.0030.00918.04
7.1.70.0060.00317.39
7.1.60.0100.01419.48
7.1.00.0030.07322.33
7.0.200.0600.00714.68
7.0.60.0070.07721.82
7.0.50.0070.04017.86
7.0.40.0200.06020.04
7.0.30.0170.05320.38
7.0.20.0200.05720.33
7.0.10.0130.06320.09
7.0.00.0170.07720.10
5.6.280.0170.06021.10
5.6.210.0130.07720.50
5.6.200.0130.07318.18
5.6.190.0130.06320.55
5.6.180.0200.05320.50
5.6.170.0170.06320.54
5.6.160.0200.07020.50
5.6.150.0200.06020.33
5.6.140.0200.05720.41
5.6.130.0130.06020.21
5.6.120.0100.07020.33
5.6.110.0170.05020.30
5.6.100.0300.05020.40
5.6.90.0500.06020.50
5.6.80.0170.05019.72
5.6.70.0430.05319.82
5.6.60.0370.06719.68
5.6.50.0470.05019.82
5.6.40.0370.05719.66
5.6.30.0470.05019.57
5.6.20.0530.07019.61
5.6.10.0430.06319.66
5.6.00.0500.05719.65
5.5.350.0170.06320.42
5.5.340.0100.07718.02
5.5.330.0170.06020.38
5.5.320.0330.06020.56
5.5.310.0270.04720.46
5.5.300.0200.05720.24
5.5.290.0230.06720.32
5.5.280.0100.07020.13
5.5.270.0070.07020.14
5.5.260.0530.05320.23
5.5.250.0470.05319.94
5.5.240.0230.06019.54
5.5.230.0400.06319.70
5.5.220.0400.06719.39
5.5.210.0470.05319.70
5.5.200.0430.05319.50
5.5.190.0570.05719.46
5.5.180.0770.06019.56
5.5.160.0570.05019.48
5.5.150.0570.05019.40
5.5.140.0700.04719.36
5.5.130.0430.06019.36
5.5.120.0500.05319.48
5.5.110.0500.04319.59
5.5.100.0400.06019.35
5.5.90.0100.06319.36
5.5.80.0170.06019.34
5.5.70.0300.04319.18
5.5.60.0130.05719.38
5.5.50.0130.05719.57
5.5.40.0100.05719.43
5.5.30.0200.05019.38
5.5.20.0170.05319.45
5.5.10.0200.06319.43
5.5.00.0170.06019.29