3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $re1=".*?"; # Non-greedy match on filler $re2="(\\[)"; # Any Single Character 1 $re3="(n)"; # Any Single Character 2 $re4="(i)"; # Any Single Character 3 $re5="(d)"; # Any Single Character 4 $re6="(:)"; # Any Single Character 5 $txt="iasduad iiabefibasdib [nid:112] oabsdo baosd [10] [n10]"; if ($c=preg_match_all ("/".$re1.$re2.$re3.$re4.$re5.$re6."/is", $txt, $matches)) { $c1=$matches[1][0]; $c2=$matches[2][0]; $c3=$matches[3][0]; $c4=$matches[4][0]; $c5=$matches[5][0]; print "($c1) ($c2) ($c3) ($c4) ($c5) \n"; }
based on ksTiM

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.00.0130.00719.05
7.1.100.0040.01117.80
7.1.70.0070.00416.68
7.1.60.0000.01117.19
7.1.50.0040.00816.87
7.1.00.0000.08022.51
7.0.200.0070.01016.70
7.0.140.0030.07322.01
7.0.60.0070.04019.92
7.0.50.0000.04317.80
7.0.40.0030.07320.02
7.0.30.0470.06020.09
7.0.20.0170.04320.19
7.0.10.0100.07720.09
7.0.00.0100.07720.01
5.6.280.0100.06720.81
5.6.210.0070.08720.74
5.6.200.0200.06718.13
5.6.190.0100.04320.56
5.6.180.0200.04320.57
5.6.170.0300.08020.36
5.6.160.0070.08020.50
5.6.150.0070.07718.21
5.6.140.0130.07318.16
5.6.130.0100.07318.20
5.6.120.0070.04021.13
5.6.110.0170.06321.11
5.6.100.0000.04320.96
5.6.90.0170.05320.94
5.6.80.0170.06720.39
5.6.70.4500.03320.41
5.5.350.0270.05720.52
5.5.340.0070.03317.97
5.5.330.0130.08020.40
5.5.320.0230.05720.18
5.5.310.0300.03720.17
5.5.300.0070.07018.01
5.5.290.0030.07718.01
5.5.280.0000.04320.84
5.5.270.0030.08320.87
5.5.260.0070.08720.86
5.5.250.0100.06720.77
5.5.240.0230.04320.27
5.4.450.1870.03319.43
5.4.440.1400.05019.42
5.4.430.0030.03719.45
5.4.420.0030.03719.20
5.4.410.0800.05319.25
5.4.400.1570.03719.04
5.4.390.1930.03718.93
5.4.380.1930.03719.21
5.4.370.1900.03719.07
5.4.360.2070.04719.08
5.4.350.0930.04319.07
5.4.340.0000.05319.24
5.4.320.0030.03718.80
5.4.310.0100.04318.91
5.4.300.1670.03719.07
5.4.290.1800.04019.24
5.4.280.2070.04018.78
5.4.270.1270.04318.88
5.4.260.0070.04718.88
5.4.250.0070.04019.21
5.4.240.1270.04019.23
5.4.230.2030.04019.23
5.4.220.1330.04719.16
5.4.210.1670.03719.12
5.4.200.1730.04019.05
5.4.190.1270.05019.11
5.4.180.0000.04019.11
5.4.170.0000.04018.79
5.4.160.1370.04019.08
5.4.150.1030.03719.02
5.4.140.0000.04716.26
5.4.130.0030.03716.42
5.4.120.0030.07016.34
5.4.110.1870.03716.30
5.4.100.1870.03716.45
5.4.90.1330.03316.38
5.4.80.0100.04016.41
5.4.70.0070.05716.29
5.4.60.1030.04016.38
5.4.50.2070.03716.38
5.4.40.1730.03316.27
5.4.30.1670.03316.46
5.4.20.1630.03716.40
5.4.10.1330.03316.35
5.4.00.1330.03315.76
5.3.290.2170.04714.61
5.3.280.1770.04714.45
5.3.270.2070.04714.46
5.3.260.1630.04014.45
5.3.250.1430.04314.65
5.3.240.0100.07014.46
5.3.230.0100.07014.43
5.3.220.1300.03714.51
5.3.210.1830.03714.46
5.3.200.1800.04014.58
5.3.190.2070.04014.50
5.3.180.1970.05014.50
5.3.170.2100.04014.42
5.3.160.1800.04014.41
5.3.150.2170.03314.41
5.3.140.1830.04014.39
5.3.130.2200.04014.50
5.3.120.1600.04014.49
5.3.110.0000.04714.49
5.3.100.0170.04713.88
5.3.90.1330.06013.97
5.3.80.2000.04313.84
5.3.70.1870.04013.92
5.3.60.1900.05013.91
5.3.50.2030.03713.81
5.3.40.1800.04013.80
5.3.30.2030.04013.75
5.3.20.1570.05313.67
5.3.10.1900.02713.61
5.3.00.1800.05313.58
5.2.170.1170.02711.05
5.2.160.0070.04710.98
5.2.150.0000.04310.99
5.2.140.0300.03711.00
5.2.130.1700.03310.95
5.2.120.1600.03010.96
5.2.110.1900.02311.25
5.2.100.1530.03311.11
5.2.90.1830.03710.95
5.2.80.1470.03711.10
5.2.70.1530.03010.92
5.2.60.1530.02710.98
5.2.50.1770.03010.95
5.2.40.1430.03311.00
5.2.30.1630.03010.80
5.2.20.1170.02710.80
5.2.10.1200.02711.01
5.2.00.1270.02710.66
5.1.60.1270.02010.11
5.1.50.1170.02710.07
5.1.40.1070.0239.87
5.1.30.1370.02310.29
5.1.20.1270.02310.31
5.1.10.1470.03010.03
5.1.00.1430.02310.00
5.0.50.0730.0238.59
5.0.40.0770.0238.29
5.0.30.0730.0378.36
5.0.20.0800.0308.32
5.0.10.0730.0238.31
5.0.00.0670.0308.07
4.4.90.0600.0177.70
4.4.80.0470.0177.70
4.4.70.0800.0237.70
4.4.60.0600.0177.70
4.4.50.0730.0177.70
4.4.40.0600.0277.70
4.4.30.0000.0207.70
4.4.20.0030.0377.70
4.4.10.0070.0307.70
4.4.00.0000.0577.70
4.3.110.0000.0207.70
4.3.100.0000.0237.70
4.3.90.0000.0207.70
4.3.80.0200.0507.70
4.3.70.0530.0137.70
4.3.60.0830.0207.70
4.3.50.0530.0137.70
4.3.40.0700.0307.70
4.3.30.0370.0177.70
4.3.20.0400.0137.70
4.3.10.0330.0137.70
4.3.00.0330.0137.70