3v4l.org

run code in 300+ PHP versions simultaneously
<?php $text = 'qwe <a href="/asd/ghj/wer.html">123</a>, qwe <a href="http://www.arrivo.ru/asdwer.html">123</a>, <a href=\'http://www.arrivo.ru/asdwer.html\'>123</a>, qwe <a title="http://arrivo.ru/123.html" href=//arrivo.ru/w/sd/ger.html title="http://arrivo.ru/123.html">123</a> <a title="http://arrivo.ru/123.html" href=//arrivo.ru/w/sd/ger.html>123</a>, qwe <a href=http://yandex.ru/index.html title="smth">123</a>, qwe <a href="/smth/else">123</a>, http://www.arrivo.ru/nooo.html :)'; $text = preg_replace('#href(\s*)=(\s*)(|"|\')(\s*)((http:|https:)?//(www\.)?arrivo\.ru)/(.+)\.html(.+)(>|\s|"|\')#isU', 'href$1=$2$3$4$5/$8$9$10', $text); $text = preg_replace('#href(\s*)=(\s*)(|"|\')(\s*)(/[^/])/(.+)\.html(.+)(>|\s|"|\')#isU', 'href$1=$2$3$4$5/$6$7$8', $text); echo $text;

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)
8.3.60.0000.01516.63
8.3.50.0100.01022.12
8.3.40.0120.00318.84
8.3.30.0110.00319.15
8.3.20.0000.00820.16
8.3.10.0030.00521.91
8.3.00.0060.00319.51
8.2.180.0110.01118.56
8.2.170.0170.00322.96
8.2.160.0030.01020.43
8.2.150.0040.00424.18
8.2.140.0080.00024.66
8.2.130.0040.00426.16
8.2.120.0050.00319.79
8.2.110.0030.00721.16
8.2.100.0060.00617.75
8.2.90.0000.00819.13
8.2.80.0040.00417.97
8.2.70.0040.00417.75
8.2.60.0000.00817.80
8.2.50.0080.00518.07
8.2.40.0030.00518.16
8.2.30.0040.00417.92
8.2.20.0050.00317.90
8.2.10.0040.00418.04
8.2.00.0040.00418.06
8.1.280.0100.01025.92
8.1.270.0030.00620.81
8.1.260.0050.00226.35
8.1.250.0040.00428.09
8.1.240.0080.00321.12
8.1.230.0040.00818.96
8.1.220.0040.00417.74
8.1.210.0080.00018.77
8.1.200.0030.00617.36
8.1.190.0040.00417.23
8.1.180.0040.00418.10
8.1.170.0000.00820.39
8.1.160.0020.00522.05
8.1.150.0000.00718.81
8.1.140.0080.00017.61
8.1.130.0000.00717.78
8.1.120.0080.00017.60
8.1.110.0040.00417.55
8.1.100.0040.00417.46
8.1.90.0050.00317.58
8.1.80.0040.00417.54
8.1.70.0030.00317.52
8.1.60.0040.00417.61
8.1.50.0030.00617.55
8.1.40.0040.00417.64
8.1.30.0080.00017.70
8.1.20.0050.00317.73
8.1.10.0040.00417.50
8.1.00.0000.00817.49
8.0.300.0040.00418.77
8.0.290.0000.00716.88
8.0.280.0030.00318.48
8.0.270.0000.00717.29
8.0.260.0000.00717.26
8.0.250.0000.00717.03
8.0.240.0000.00617.00
8.0.230.0030.00317.05
8.0.220.0000.00717.00
8.0.210.0040.00417.06
8.0.200.0000.00717.06
8.0.190.0060.00316.90
8.0.180.0000.00717.00
8.0.170.0040.00416.89
8.0.160.0000.00817.00
8.0.150.0070.00016.93
8.0.140.0060.00316.94
8.0.130.0030.00313.41
8.0.120.0070.00016.93
8.0.110.0080.00016.95
8.0.100.0040.00417.01
8.0.90.0040.00416.97
8.0.80.0100.00716.98
8.0.70.0000.00816.79
8.0.60.0070.00016.88
8.0.50.0000.00816.85
8.0.30.0090.01517.07
8.0.20.0090.01217.46
8.0.10.0000.00717.06
8.0.00.0110.01016.98
7.4.330.0000.00515.11
7.4.320.0070.00016.81
7.4.300.0030.00316.56
7.4.290.0000.00716.67
7.4.280.0040.00416.74
7.4.270.0030.00516.73
7.4.260.0040.00716.59
7.4.250.0000.00716.54
7.4.240.0060.00216.70
7.4.230.0030.00316.77
7.4.220.0110.00716.79
7.4.210.0080.01016.66
7.4.200.0030.00316.65
7.4.160.0060.00916.43
7.4.150.0060.01217.40
7.4.140.0130.00817.86
7.4.130.0080.01216.61
7.4.120.0080.01216.72
7.4.110.0170.00316.72
7.4.100.0030.01316.65
7.4.90.0110.00816.70
7.4.80.0130.00319.39
7.4.70.0040.01216.61
7.4.60.0130.00316.85
7.4.50.0080.00016.73
7.4.40.0030.01416.70
7.4.30.0100.01016.56
7.4.00.0100.00315.06
7.3.330.0030.00313.20
7.3.320.0140.00013.11
7.3.310.0000.00716.37
7.3.300.0000.00716.36
7.3.290.0030.00316.40
7.3.280.0100.00516.39
7.3.270.0100.00717.40
7.3.260.0170.00016.39
7.3.250.0110.00816.64
7.3.240.0130.00316.48
7.3.230.0190.00016.56
7.3.210.0060.01216.54
7.3.200.0040.01519.39
7.3.190.0130.00616.62
7.3.180.0090.00916.41
7.3.170.0080.00816.40
7.3.160.0100.00716.70
7.2.330.0090.00916.61
7.2.320.0130.00316.54
7.2.310.0120.00616.71
7.2.300.0100.00716.81
7.2.290.0120.01216.82
7.2.00.0070.01719.37
7.1.100.0080.00318.56
7.1.70.0030.00617.50
7.1.60.0110.01419.50
7.1.50.0070.00717.17
7.1.00.0070.07322.54
7.0.200.0090.00315.18
7.0.140.0000.07721.92
7.0.60.0030.04319.95
7.0.50.0130.06717.93
7.0.40.0100.08720.43
7.0.30.0200.07720.03
7.0.20.0330.06320.23
7.0.10.0070.05320.08
7.0.00.0100.06720.02
5.6.280.0030.07021.10
5.6.210.0030.04720.47
5.6.200.0070.08018.25
5.6.190.0200.04720.39
5.6.180.0230.03720.61
5.6.170.0300.05020.46
5.6.160.0070.06720.50
5.6.150.0000.08718.12
5.6.140.0130.08018.12
5.6.130.0070.04718.06
5.6.120.0070.07321.02
5.6.110.0030.04321.01
5.6.100.0070.08021.11
5.6.90.0070.04320.96
5.6.80.0100.07020.48
5.5.350.0130.07020.43
5.5.340.0030.04017.93
5.5.330.0070.05320.15
5.5.320.3470.04320.50
5.5.310.0200.04320.31
5.5.300.0100.05017.97
5.5.290.0070.04317.96
5.5.280.0070.04020.64
5.5.270.0130.07720.88
5.5.260.0030.06720.86
5.5.250.0030.04020.54
5.5.240.0130.07320.23
5.4.450.2000.05019.58
5.4.440.1830.04319.40
5.4.430.2000.04719.39
5.4.420.2000.03719.43
5.4.410.1700.04019.27
5.4.400.1800.03319.25
5.4.390.2030.04319.09
5.4.380.2000.04719.22
5.4.370.1900.05019.06
5.4.360.2000.04318.89
5.4.350.1970.03319.24
5.4.340.1700.04318.81
5.4.320.1830.03719.08
5.4.310.1930.04319.13
5.4.300.2130.03319.08
5.4.290.2000.04319.16
5.4.280.1530.04318.80
5.4.270.1730.03719.24
5.4.260.2070.03719.14
5.4.250.1900.04319.23
5.4.240.1700.04018.91
5.4.230.1930.03019.07
5.4.220.1700.04319.06
5.4.210.1730.03719.08
5.4.200.1900.03719.08
5.4.190.1870.03319.07
5.4.180.1730.03719.24
5.4.170.1870.04019.27
5.4.160.1770.04019.06
5.4.150.1800.03719.05
5.4.140.1870.04016.20
5.4.130.1930.04316.25
5.4.120.1830.04016.25
5.4.110.1830.04016.38
5.4.100.1870.03716.18
5.4.90.2000.04316.30
5.4.80.2030.03716.46
5.4.70.1870.04016.35
5.4.60.1870.02716.36
5.4.50.1800.03316.17
5.4.40.1830.02716.36
5.4.30.2100.04316.42
5.4.20.2070.03716.45
5.4.10.1830.03716.27
5.4.00.1730.03715.77
5.3.290.2000.04314.71
5.3.280.1730.04314.69
5.3.270.1770.04014.65
5.3.260.1930.03714.47
5.3.250.1930.03714.59
5.3.240.1900.03714.70
5.3.230.2030.04714.43
5.3.220.1770.04314.42
5.3.210.1900.03314.43
5.3.200.1770.03714.58
5.3.190.1600.03014.51
5.3.180.1670.03714.50
5.3.170.1830.03314.40
5.3.160.1830.03314.61
5.3.150.1770.04714.52
5.3.140.2130.04714.50
5.3.130.2130.04314.59
5.3.120.1900.03314.64
5.3.110.1800.03714.42
5.3.100.1900.03013.88
5.3.90.1830.03313.85
5.3.80.2100.04013.81
5.3.70.1730.04013.96
5.3.60.1870.03313.95
5.3.50.1870.04013.82
5.3.40.2100.03714.04
5.3.30.1630.03713.71
5.3.20.2130.03313.66
5.3.10.2170.03313.53
5.3.00.2030.04313.54
5.2.170.1400.03311.19
5.2.160.1670.04011.20
5.2.150.1630.03311.15
5.2.140.1470.03011.00
5.2.130.1700.03311.15
5.2.120.1570.03311.04
5.2.110.1670.02710.95
5.2.100.1530.02311.01
5.2.90.1430.03010.98
5.2.80.1530.02711.11
5.2.70.1500.02710.95
5.2.60.1470.03011.10
5.2.50.1670.03710.87
5.2.40.1270.03710.91
5.2.30.1100.03010.84
5.2.20.1370.03011.06
5.2.10.1200.03710.90
5.2.00.1370.02310.79
5.1.60.1330.0279.97
5.1.50.1100.0279.97
5.1.40.1130.03710.02
5.1.30.1400.03010.45
5.1.20.1330.03310.30
5.1.10.1470.02710.18
5.1.00.1100.03010.23
5.0.50.0730.0238.41
5.0.40.0730.0308.29
5.0.30.0670.0408.19
5.0.20.0830.0308.09
5.0.10.0600.0238.32
5.0.00.0700.0478.08
4.4.90.0530.0177.92
4.4.80.0630.0207.92
4.4.70.0730.0237.93
4.4.60.0800.0207.93
4.4.50.0600.0177.93
4.4.40.0530.0277.94
4.4.30.0630.0107.94
4.4.20.0570.0137.94
4.4.10.0700.0237.95
4.4.00.0630.0307.96
4.3.110.0670.0177.96
4.3.100.0630.0237.96
4.3.90.0730.0277.96
4.3.80.0530.0277.96
4.3.70.0570.0177.96
4.3.60.0570.0137.96
4.3.50.0570.0137.96
4.3.40.0600.0307.96
4.3.30.0300.0137.96
4.3.20.0370.0237.96
4.3.10.0330.0177.96
4.3.00.0330.0107.96

preferences:
77.09 ms | 401 KiB | 5 Q