3v4l.org

run code in 300+ PHP versions simultaneously
<?php $text = 'say hello to @elise_123 and @john-abc'; function replace_at_symbol($matches){ $username = str_replace("@", "", $matches[0]); return '<a href="/profile/'.$username.'">'.$matches[0].'</a>';} $output = preg_replace_callback("/([@][-_a-zA-Z-0-9]+)/", "replace_at_symbol", $text); echo $output; ?>

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.0080.00818.56
8.3.50.0090.00822.09
8.3.40.0120.00318.79
8.3.30.0110.00419.13
8.3.20.0040.00420.29
8.3.10.0000.00721.90
8.3.00.0050.00317.91
8.2.180.0100.01018.32
8.2.170.0150.00022.96
8.2.160.0110.00320.20
8.2.150.0000.00824.18
8.2.140.0000.00824.66
8.2.130.0050.00326.16
8.2.120.0040.00421.08
8.2.110.0000.01019.30
8.2.100.0060.00617.91
8.2.90.0080.00017.96
8.2.80.0000.00817.97
8.2.70.0030.00617.88
8.2.60.0080.00018.03
8.2.50.0050.00518.07
8.2.40.0080.00018.22
8.2.30.0000.00718.13
8.2.20.0080.00017.89
8.2.10.0030.00518.21
8.2.00.0000.00817.90
8.1.280.0070.01125.92
8.1.270.0040.00423.96
8.1.260.0040.00426.35
8.1.250.0060.00328.09
8.1.240.0030.00921.89
8.1.230.0000.01220.95
8.1.220.0040.00417.74
8.1.210.0000.00818.96
8.1.200.0040.00817.50
8.1.190.0040.00417.13
8.1.180.0040.00418.10
8.1.170.0090.00018.69
8.1.160.0040.00421.95
8.1.150.0050.00318.82
8.1.140.0040.00417.61
8.1.130.0070.00017.77
8.1.120.0000.00717.52
8.1.110.0000.00817.60
8.1.100.0000.00717.69
8.1.90.0050.00217.59
8.1.80.0030.00417.50
8.1.70.0050.00317.52
8.1.60.0090.00017.71
8.1.50.0050.00317.74
8.1.40.0040.00717.68
8.1.30.0040.00417.84
8.1.20.0070.00017.80
8.1.10.0000.00817.64
8.1.00.0000.00717.55
8.0.300.0000.00719.79
8.0.290.0000.00716.88
8.0.280.0000.00718.46
8.0.270.0070.00017.33
8.0.260.0030.00317.32
8.0.250.0000.00717.21
8.0.240.0070.00017.04
8.0.230.0070.00017.04
8.0.220.0000.00716.93
8.0.210.0070.00017.07
8.0.200.0070.00017.05
8.0.190.0040.00417.01
8.0.180.0080.00417.04
8.0.170.0040.00417.06
8.0.160.0000.00816.87
8.0.150.0050.00216.85
8.0.140.0050.00317.05
8.0.130.0000.00613.43
8.0.120.0080.00017.08
8.0.110.0000.00717.09
8.0.100.0040.00416.94
8.0.90.0030.00316.87
8.0.80.0110.00417.01
8.0.70.0080.00017.15
8.0.60.0040.00417.04
8.0.50.0040.00417.07
8.0.30.0080.01117.38
8.0.20.0170.01017.45
8.0.10.0000.00717.01
8.0.00.0120.00816.97
7.4.330.0020.00215.09
7.4.320.0030.00316.84
7.4.300.0040.00416.82
7.4.290.0040.00416.81
7.4.280.0030.00516.62
7.4.270.0030.00316.63
7.4.260.0070.00016.73
7.4.250.0040.00416.83
7.4.240.0000.00716.75
7.4.230.0000.00716.84
7.4.220.0130.01316.80
7.4.210.0140.00316.59
7.4.200.0000.00716.85
7.4.160.0120.01216.70
7.4.150.0070.01117.40
7.4.140.0040.01617.86
7.4.130.0120.00816.66
7.4.120.0050.01116.73
7.4.110.0150.00716.64
7.4.100.0110.01216.64
7.4.90.0070.01016.88
7.4.80.0000.01619.39
7.4.70.0060.01116.59
7.4.60.0090.00916.78
7.4.50.0040.00416.65
7.4.40.0100.01316.50
7.4.30.0050.01116.73
7.4.00.0100.00715.00
7.3.330.0050.00013.47
7.3.320.0030.00313.56
7.3.310.0070.00016.58
7.3.300.0040.00416.47
7.3.290.0040.01116.50
7.3.280.0070.00816.48
7.3.270.0060.01217.40
7.3.260.0080.00916.73
7.3.250.0100.00716.67
7.3.240.0060.01216.49
7.3.230.0070.01516.56
7.3.210.0070.01016.73
7.3.200.0230.00019.39
7.3.190.0130.00616.70
7.3.180.0060.00916.75
7.3.170.0060.00916.52
7.3.160.0100.00716.51
7.3.120.0070.01014.91
7.3.110.0160.00314.95
7.3.100.0030.00914.78
7.3.90.0060.00914.98
7.3.80.0150.00015.00
7.3.70.0040.00415.07
7.3.60.0080.00814.98
7.3.50.0100.01015.02
7.3.40.0060.00915.04
7.3.30.0100.00614.97
7.3.20.0130.00616.60
7.3.10.0070.01116.50
7.3.00.0110.00016.57
7.2.330.0100.00716.85
7.2.320.0120.00616.80
7.2.310.0120.00916.96
7.2.300.0030.01316.91
7.2.290.0100.01016.89
7.2.250.0040.01415.30
7.2.240.0070.01415.20
7.2.230.0100.00715.20
7.2.220.0030.01215.16
7.2.210.0120.00415.14
7.2.200.0050.00514.97
7.2.190.0030.01615.44
7.2.180.0060.01215.21
7.2.170.0040.01115.30
7.2.60.0110.00317.26
7.2.00.0030.01419.73
7.1.330.0110.00415.79
7.1.320.0100.00615.81
7.1.310.0000.01016.12
7.1.300.0060.00615.90
7.1.290.0070.01115.74
7.1.280.0070.00315.64
7.1.270.0090.00616.10
7.1.260.0040.01216.08
7.1.200.0000.01415.80
7.1.100.0060.00918.57
7.1.70.0000.00717.46
7.1.60.0110.00819.25
7.1.50.0100.01317.11
7.1.00.0070.07322.32
7.0.200.0050.00216.78
7.0.140.0130.06322.05
7.0.60.0100.03719.80
7.0.50.0130.07317.86
7.0.40.0100.08020.20
7.0.30.0270.04020.43
7.0.20.0400.08020.09
7.0.10.0070.04020.25
7.0.00.0030.05720.13
5.6.280.0000.07721.07
5.6.210.0130.08020.44
5.6.200.0030.07718.34
5.6.190.0070.06020.64
5.6.180.0400.07320.34
5.6.170.0200.06720.71
5.6.160.0000.04320.55
5.6.150.0070.04718.20
5.6.140.0130.07318.23
5.6.130.0000.07318.18
5.6.120.0170.06320.98
5.6.110.0100.07720.99
5.6.100.0100.07321.03
5.6.90.0100.07720.94
5.6.80.0130.06720.38
5.5.350.0070.08020.35
5.5.340.0030.07317.95
5.5.330.0000.05720.13
5.5.320.0200.04320.35
5.5.310.0500.06320.34
5.5.300.0070.06717.97
5.5.290.0130.07318.02
5.5.280.0000.04320.89
5.5.270.0130.07720.68
5.5.260.0130.07320.89
5.5.250.0200.07020.68
5.5.240.0270.08320.13
5.4.450.0100.05719.32
5.4.440.0370.05019.48
5.4.430.0370.04319.27
5.4.420.0230.04719.57
5.4.410.0130.04319.39
5.4.400.0470.03718.96
5.4.390.0530.04019.09
5.4.380.0830.05718.79
5.4.370.0830.05318.71
5.4.360.0970.05318.63
5.4.350.1330.05318.78
5.4.340.0600.04018.56
5.4.320.0030.04012.50
5.4.310.0060.03812.50
5.4.300.0090.03412.50
5.4.290.0080.03612.50
5.4.280.0050.03712.40
5.4.270.0080.03512.40
5.4.260.0050.03912.39
5.4.250.0080.03612.40
5.4.240.0050.03712.40
5.4.230.0070.03712.39
5.4.220.0040.03812.39
5.4.210.0050.03612.39
5.4.200.0090.03512.39
5.4.190.0060.03612.38
5.4.180.0080.03412.39
5.4.170.0090.03312.39
5.4.160.0100.03112.39
5.4.150.0060.03612.39
5.4.140.0080.03412.07
5.4.130.0120.02912.06
5.4.120.0080.03312.02
5.4.110.0080.03312.01
5.4.100.0080.03312.02
5.4.90.0070.03612.02
5.4.80.0080.03512.02
5.4.70.0080.03312.01
5.4.60.0130.02812.00
5.4.50.0070.03512.01
5.4.40.0050.03612.00
5.4.30.0060.03612.00
5.4.20.0040.03811.99
5.4.10.0070.03411.99
5.4.00.0070.03511.48
5.3.290.0050.04512.80
5.3.280.0040.04012.71
5.3.270.0070.03912.72
5.3.260.0040.04012.72
5.3.250.0080.03412.71
5.3.240.0070.03512.72
5.3.230.0060.03812.71
5.3.220.0090.03412.68
5.3.210.0060.04012.68
5.3.200.0020.04112.68
5.3.190.0080.03912.68
5.3.180.0090.03512.68
5.3.170.0050.04412.67
5.3.160.0090.03912.67
5.3.150.0110.03212.67
5.3.140.0070.04112.66
5.3.130.0070.03812.66
5.3.120.0070.03912.66
5.3.110.0050.03912.66
5.3.100.0090.03612.13
5.3.90.0090.03312.11
5.3.80.0060.03612.10
5.3.70.0060.03812.10
5.3.60.0050.03812.09
5.3.50.0050.03612.04
5.3.40.0050.04012.03
5.3.30.0060.03911.99
5.3.20.0070.03711.78
5.3.10.0070.03311.74
5.3.00.0040.03811.73
5.2.170.0050.0309.23
5.2.160.0050.0299.23
5.2.150.0050.0299.23
5.2.140.0090.0329.22
5.2.130.0060.0359.19
5.2.120.0060.0289.19
5.2.110.0030.0309.20
5.2.100.0050.0289.19
5.2.90.0050.0299.19
5.2.80.0040.0309.18
5.2.70.0030.0319.18
5.2.60.0050.0399.14
5.2.50.0060.0359.11
5.2.40.0050.0339.09
5.2.30.0060.0299.07
5.2.20.0080.0279.05
5.2.10.0020.0368.94
5.2.00.0060.0278.80
5.1.60.0040.0248.09
5.1.50.0040.0258.09
5.1.40.0050.0238.06
5.1.30.0070.0258.41
5.1.20.0050.0248.43
5.1.10.0030.0268.16
5.1.00.0030.0268.16
5.0.50.0050.0216.64
5.0.40.0050.0246.50
5.0.30.0070.0306.30
5.0.20.0030.0206.27
5.0.10.0070.0226.25
5.0.00.0050.0296.25
4.4.90.0040.0144.78
4.4.80.0040.0164.75
4.4.70.0030.0174.75
4.4.60.0030.0154.75
4.4.50.0070.0164.77
4.4.40.0010.0264.71
4.4.30.0020.0184.76
4.4.20.0020.0214.84
4.4.10.0030.0154.85
4.4.00.0030.0254.76
4.3.110.0070.0134.67
4.3.100.0040.0144.67
4.3.90.0030.0144.63
4.3.80.0030.0264.59
4.3.70.0030.0184.63
4.3.60.0020.0274.62
4.3.50.0060.0184.63
4.3.40.0050.0274.54
4.3.30.0020.0213.30
4.3.20.0020.0193.27
4.3.10.0030.0143.24
4.3.00.0030.02015.28

preferences:
66.59 ms | 401 KiB | 5 Q