3v4l.org

run code in 300+ PHP versions simultaneously
<?php $searchTerm = "ΓΌ"; $replaceTerm = "%FC"; $test=array("${searchTerm}/${searchTerm}_.${searchTerm}", "xay${searchTerm}", "asdasd/${searchTerm}.mp3", "${searchTerm}.", "blahahbasd${searchTerm}", "1234${searchTerm}1234"); foreach ($test as $t) echo "$t => " . preg_replace("/". preg_quote($searchTerm) . "([^_.]|$)/x", preg_quote($replaceTerm) . "\${1}", $t) . "\n";

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.0100.00716.75
8.3.50.0100.00722.03
8.3.40.0070.01418.96
8.3.30.0100.00419.11
8.3.20.0080.00020.35
8.3.10.0030.00623.52
8.3.00.0080.00017.91
8.2.180.0110.00416.63
8.2.170.0080.00822.96
8.2.160.0030.01020.52
8.2.150.0030.00524.18
8.2.140.0090.00024.66
8.2.130.0040.00426.16
8.2.120.0000.00820.86
8.2.110.0030.00619.22
8.2.100.0120.00018.03
8.2.90.0080.00019.26
8.2.80.0080.00017.97
8.2.70.0000.00817.63
8.2.60.0030.00619.78
8.2.50.0040.00418.16
8.2.40.0050.00220.47
8.2.30.0000.00819.33
8.2.20.0000.00817.71
8.2.10.0080.00018.16
8.2.00.0040.00419.68
8.1.280.0120.00325.92
8.1.270.0080.00023.79
8.1.260.0070.00026.35
8.1.250.0070.00028.09
8.1.240.0060.00321.16
8.1.230.0070.00417.70
8.1.220.0030.00617.77
8.1.210.0030.00618.77
8.1.200.0050.00517.24
8.1.190.0050.00317.25
8.1.180.0030.00518.10
8.1.170.0000.00818.59
8.1.160.0030.00518.84
8.1.150.0040.00420.20
8.1.140.0080.00017.59
8.1.130.0000.00817.87
8.1.120.0040.00417.48
8.1.110.0040.00417.68
8.1.100.0000.00717.57
8.1.90.0000.00717.62
8.1.80.0000.00717.67
8.1.70.0020.00517.50
8.1.60.0000.00817.75
8.1.50.0000.00917.69
8.1.40.0040.00417.68
8.1.30.0060.00317.69
8.1.20.0000.00817.86
8.1.10.0000.00817.63
8.1.00.0020.00517.49
8.0.300.0000.00718.77
8.0.290.0050.00316.75
8.0.280.0050.00318.39
8.0.270.0040.00317.19
8.0.260.0070.00017.28
8.0.250.0070.00017.13
8.0.240.0000.00817.17
8.0.230.0000.00717.06
8.0.220.0070.00017.05
8.0.210.0090.00017.06
8.0.200.0000.00717.12
8.0.190.0050.00217.13
8.0.180.0040.00417.02
8.0.170.0040.00417.05
8.0.160.0060.00316.94
8.0.150.0040.00416.86
8.0.140.0000.00717.04
8.0.130.0030.00313.50
8.0.120.0030.00617.03
8.0.110.0080.00017.02
8.0.100.0040.00416.83
8.0.90.0080.00016.93
8.0.80.0070.01017.00
8.0.70.0040.00416.92
8.0.60.0070.00016.82
8.0.50.0050.00317.02
8.0.30.0080.01317.29
8.0.20.0160.00917.45
8.0.10.0030.00517.14
8.0.00.0110.00916.99
7.4.330.0000.00615.04
7.4.320.0000.00616.80
7.4.300.0050.00316.78
7.4.290.0070.00016.83
7.4.280.0000.00716.71
7.4.270.0040.00416.79
7.4.260.0070.00016.80
7.4.250.0000.00716.83
7.4.240.0050.00216.72
7.4.230.0000.00716.56
7.4.220.0180.00916.82
7.4.210.0000.01816.71
7.4.200.0050.00216.53
7.4.160.0120.00416.80
7.4.150.0150.00617.40
7.4.140.0120.00617.86
7.4.130.0130.00316.79
7.4.120.0100.00716.76
7.4.110.0200.00016.79
7.4.100.0090.00916.63
7.4.90.0100.00716.49
7.4.80.0150.00919.39
7.4.70.0120.00616.80
7.4.60.0100.00716.58
7.4.50.0030.00316.84
7.4.40.0120.00316.66
7.4.30.0090.00616.70
7.4.00.0080.00715.18
7.3.330.0000.00613.41
7.3.320.0030.00313.21
7.3.310.0000.00716.35
7.3.300.0040.00416.52
7.3.290.0040.01116.51
7.3.280.0090.01116.48
7.3.270.0100.01017.40
7.3.260.0140.00316.39
7.3.250.0140.00616.52
7.3.240.0140.00416.63
7.3.230.0090.01316.44
7.3.210.0100.00716.78
7.3.200.0090.00619.39
7.3.190.0040.01816.45
7.3.180.0100.00616.77
7.3.170.0180.00016.50
7.3.160.0060.01016.57
7.3.120.0040.01214.82
7.3.110.0100.01015.20
7.3.100.0040.01114.80
7.3.90.0120.00614.95
7.3.80.0090.00615.23
7.3.70.0040.00815.02
7.3.60.0060.00914.89
7.3.50.0040.01414.96
7.3.40.0140.00315.07
7.3.30.0030.01114.85
7.3.20.0080.00416.64
7.3.10.0100.00816.78
7.3.00.0130.00416.59
7.2.330.0090.00916.85
7.2.320.0070.01016.73
7.2.310.0060.01217.01
7.2.300.0090.00916.66
7.2.290.0100.00616.80
7.2.250.0100.01015.17
7.2.240.0070.01415.44
7.2.230.0030.01414.92
7.2.220.0060.00315.23
7.2.210.0030.01715.00
7.2.200.0070.00714.84
7.2.190.0030.00915.18
7.2.180.0130.00315.11
7.2.170.0090.00015.41
7.2.130.0170.00716.44
7.2.120.0180.00416.86
7.2.110.0150.00616.38
7.2.100.0160.00316.61
7.2.90.0160.00616.82
7.2.80.0090.01316.89
7.2.70.0180.00616.79
7.2.60.0130.00516.91
7.2.50.0120.00416.99
7.2.40.0150.00416.82
7.2.30.0160.00616.64
7.2.20.0170.00716.52
7.2.10.0170.01416.73
7.2.00.0130.01016.96
7.1.330.0100.00716.07
7.1.320.0130.00015.97
7.1.310.0090.00016.16
7.1.300.0040.01116.01
7.1.290.0000.01515.92
7.1.280.0060.00615.91
7.1.270.0070.01115.64
7.1.260.0060.00915.97
7.1.250.0080.00815.59
7.1.200.0000.01615.85
7.1.70.0030.00917.32
7.1.60.0140.01019.70
7.1.50.0160.01317.04
7.1.00.0000.07722.48
7.0.200.0030.00616.73
7.0.140.0070.06722.00
7.0.60.0030.08319.85
7.0.50.0070.04317.85
7.0.40.0130.07720.26
7.0.30.0430.06720.22
7.0.20.0300.07320.22
7.0.10.0070.08720.02
7.0.00.0000.04720.01
5.6.280.0070.07321.04
5.6.210.0070.04720.74
5.6.200.0000.06018.15
5.6.190.0100.06320.43
5.6.180.0370.07020.39
5.6.170.0170.04020.48
5.6.160.0030.04020.47
5.6.150.0070.05018.14
5.6.140.0030.05018.20
5.6.130.0000.04318.21
5.6.120.0030.08321.05
5.6.110.0030.08720.93
5.6.100.0170.07321.01
5.6.90.0100.08021.13
5.6.80.0100.07720.37
5.5.350.0270.07720.46
5.5.340.0070.05717.98
5.5.330.0200.07720.43
5.5.320.0230.04720.27
5.5.310.0270.08020.29
5.5.300.0130.05017.95
5.5.290.0200.07317.95
5.5.280.0070.04720.80
5.5.270.0070.03720.63
5.5.260.0100.08020.67
5.5.250.0100.05720.70
5.5.240.0030.07320.23
5.4.450.0930.03719.52
5.4.440.0430.06719.29
5.4.430.0130.05319.42
5.4.420.0030.06319.32
5.4.410.0230.04019.32
5.4.400.0100.05019.16
5.4.390.0230.04019.00
5.4.380.0030.06018.72
5.4.370.0030.05018.51
5.4.360.0100.03318.61
5.4.350.0060.03611.97
5.4.340.0070.03411.97
5.4.320.0050.04712.46
5.4.310.0060.04012.45
5.4.300.0090.03312.45
5.4.290.0030.04212.45
5.4.280.0060.03612.35
5.4.270.0080.03312.35
5.4.260.0090.03712.35
5.4.250.0100.03512.35
5.4.240.0100.03312.35
5.4.230.0060.03812.34
5.4.220.0050.03812.34
5.4.210.0030.03812.34
5.4.200.0060.03712.34
5.4.190.0050.03712.34
5.4.180.0060.03712.34
5.4.170.0050.03812.35
5.4.160.0090.03412.34
5.4.150.0050.03912.34
5.4.140.0090.03612.02
5.4.130.0060.03512.02
5.4.120.0060.03511.97
5.4.110.0100.03611.97
5.4.100.0060.03711.96
5.4.90.0040.03911.96
5.4.80.0060.04311.97
5.4.70.0050.03611.96
5.4.60.0050.03511.96
5.4.50.0040.03711.96
5.4.40.0070.03411.95
5.4.30.0080.03311.95
5.4.20.0070.03411.95
5.4.10.0050.03511.95
5.4.00.0030.03811.44
5.3.290.0050.04112.80
5.3.280.0110.03512.71
5.3.270.0080.03812.72
5.3.260.0100.04212.72
5.3.250.0060.03912.72
5.3.240.0080.03612.72
5.3.230.0070.03612.71
5.3.220.0070.03612.68
5.3.210.0070.04212.68
5.3.200.0050.03812.68
5.3.190.0070.03812.68
5.3.180.0130.04712.68
5.3.170.0060.03712.67
5.3.160.0050.04112.67
5.3.150.0060.03812.68
5.3.140.0070.03612.66
5.3.130.0050.04012.66
5.3.120.0100.04112.65
5.3.110.0090.05312.66
5.3.100.0060.04512.11
5.3.90.0050.03612.09
5.3.80.0100.03912.07
5.3.70.0040.03812.08
5.3.60.0070.04112.06
5.3.50.0040.03912.00
5.3.40.0070.03612.00
5.3.30.0070.03311.95
5.3.20.0060.03411.74
5.3.10.0060.03311.70
5.3.00.0040.03711.69
5.2.170.0040.0359.19
5.2.160.0050.0339.20
5.2.150.0070.0319.20
5.2.140.0020.0339.19
5.2.130.0090.0249.15
5.2.120.0050.0279.15
5.2.110.0040.0309.16
5.2.100.0050.0299.16
5.2.90.0080.0379.15
5.2.80.0050.0309.14
5.2.70.0080.0269.14
5.2.60.0020.0319.10
5.2.50.0030.0319.07
5.2.40.0070.0269.05
5.2.30.0030.0319.03
5.2.20.0090.0339.02
5.2.10.0060.0268.93
5.2.00.0030.0308.79
5.1.60.0010.0278.08
5.1.50.0010.0278.07
5.1.40.0040.0248.05
5.1.30.0030.0278.40
5.1.20.0040.0278.42
5.1.10.0060.0248.15
5.1.00.0020.0278.15
5.0.50.0020.0216.63
5.0.40.0030.0196.48
5.0.30.0020.0326.30
5.0.20.0040.0206.28
5.0.10.0040.0186.25
5.0.00.0010.0326.24
4.4.90.0030.0144.78
4.4.80.0040.0134.75
4.4.70.0000.0184.75
4.4.60.0020.0164.75
4.4.50.0020.0154.77
4.4.40.0020.0254.71
4.4.30.0020.0154.76
4.4.20.0040.0144.85
4.4.10.0020.0164.85
4.4.00.0030.0254.76
4.3.110.0010.0174.67
4.3.100.0000.0174.66
4.3.90.0070.0104.63
4.3.80.0030.0254.59
4.3.70.0030.0144.63
4.3.60.0020.0154.63
4.3.50.0010.0174.63
4.3.40.0020.0264.54
4.3.30.0020.0163.30
4.3.20.0030.0163.27
4.3.10.0010.0173.23
4.3.00.0030.0276.70

preferences:
74.67 ms | 401 KiB | 5 Q