3v4l.org

run code in 300+ PHP versions simultaneously
<?php $searchReplaceArray = array( '&#038;' => '&', ); $string = "Hello &#038; Goodbye"; $result = str_replace( array_keys($searchReplaceArray), array_values($searchReplaceArray), $string ); echo $result;

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.00316.38
8.3.50.0200.00321.94
8.3.40.0070.00718.58
8.3.30.0100.00718.97
8.3.20.0030.00620.16
8.3.10.0050.00323.66
8.3.00.0000.00719.02
8.2.180.0090.00916.63
8.2.170.0110.00422.96
8.2.160.0100.00320.45
8.2.150.0040.00424.18
8.2.140.0000.00824.66
8.2.130.0070.00026.16
8.2.120.0060.00320.82
8.2.110.0090.00022.23
8.2.100.0030.00917.72
8.2.90.0040.00419.17
8.2.80.0040.00417.97
8.2.70.0030.00617.63
8.2.60.0070.00017.93
8.2.50.0000.00818.07
8.2.40.0000.00819.89
8.2.30.0070.00018.12
8.2.20.0050.00317.65
8.2.10.0040.00418.19
8.2.00.0000.00717.74
8.1.280.0070.01125.92
8.1.270.0090.00023.87
8.1.260.0080.00026.35
8.1.250.0000.00728.09
8.1.240.0060.00323.83
8.1.230.0080.00319.16
8.1.220.0080.00017.74
8.1.210.0030.00518.77
8.1.200.0040.00417.25
8.1.190.0050.00517.00
8.1.180.0040.00418.10
8.1.170.0080.00018.53
8.1.160.0000.00722.00
8.1.150.0070.00018.58
8.1.140.0040.00417.37
8.1.130.0000.00717.77
8.1.120.0000.00717.27
8.1.110.0050.00317.30
8.1.100.0040.00417.38
8.1.90.0000.00717.40
8.1.80.0040.00417.41
8.1.70.0030.00317.30
8.1.60.0000.00917.41
8.1.50.0060.00317.42
8.1.40.0050.00317.45
8.1.30.0060.00317.54
8.1.20.0070.00017.63
8.1.10.0040.00417.38
8.1.00.0030.00617.43
8.0.300.0040.00418.77
8.0.290.0060.00317.18
8.0.280.0050.00218.52
8.0.270.0000.00717.24
8.0.260.0040.00417.24
8.0.250.0030.00316.85
8.0.240.0060.00016.98
8.0.230.0000.00716.85
8.0.220.0070.00016.69
8.0.210.0030.00316.80
8.0.200.0000.00616.88
8.0.190.0030.00616.86
8.0.180.0090.00016.79
8.0.170.0080.00016.90
8.0.160.0040.00416.77
8.0.150.0030.00516.70
8.0.140.0000.00716.65
8.0.130.0000.00813.23
8.0.120.0050.00316.84
8.0.110.0000.00716.80
8.0.100.0020.00516.59
8.0.90.0020.00516.86
8.0.80.0070.00716.77
8.0.70.0030.00316.77
8.0.60.0000.00716.64
8.0.50.0030.00616.68
8.0.30.0100.01317.00
8.0.20.0080.01117.40
8.0.10.0000.00716.96
8.0.00.0120.00516.73
7.4.330.0000.00515.00
7.4.320.0030.00616.45
7.4.300.0060.00016.54
7.4.290.0030.00316.52
7.4.280.0000.00716.40
7.4.270.0080.00016.32
7.4.260.0030.00316.55
7.4.250.0080.00016.36
7.4.240.0030.00516.47
7.4.230.0030.00316.59
7.4.220.0060.01316.53
7.4.210.0100.00816.54
7.4.200.0020.00516.52
7.4.190.0030.00316.59
7.4.160.0050.01116.31
7.4.150.0090.00917.40
7.4.140.0160.00817.86
7.4.130.0100.00616.35
7.4.120.0080.00816.39
7.4.110.0090.01216.58
7.4.100.0150.00316.40
7.4.90.0040.01416.49
7.4.80.0160.00319.39
7.4.70.0080.00816.31
7.4.60.0150.00616.35
7.4.50.0000.00416.47
7.4.40.0100.00716.57
7.4.30.0130.00316.55
7.4.00.0060.00914.91
7.3.330.0000.00613.09
7.3.320.0030.00313.11
7.3.310.0030.00316.25
7.3.300.0030.00316.17
7.3.290.0060.00916.21
7.3.280.0070.01116.22
7.3.270.0110.01117.40
7.3.260.0030.01416.21
7.3.250.0100.01016.20
7.3.240.0140.00316.36
7.3.230.0030.01416.39
7.3.210.0110.01116.30
7.3.200.0120.01219.39
7.3.190.0090.00916.42
7.3.180.0100.00716.47
7.3.170.0090.01316.41
7.3.160.0040.01216.33
7.3.120.0050.00914.92
7.3.110.0060.01214.53
7.3.100.0090.00614.77
7.3.90.0030.01214.71
7.3.80.0100.00314.76
7.3.70.0000.01214.59
7.3.60.0000.01414.69
7.3.50.0060.00914.92
7.3.40.0000.01414.43
7.3.30.0030.01314.48
7.3.20.0100.00316.59
7.3.10.0140.00316.61
7.3.00.0100.00916.27
7.2.330.0190.00316.65
7.2.320.0070.01416.65
7.2.310.0030.01316.67
7.2.300.0170.00016.44
7.2.290.0070.01016.41
7.2.250.0060.00915.16
7.2.240.0130.00614.95
7.2.230.0030.01315.11
7.2.220.0030.01015.09
7.2.210.0070.00715.07
7.2.200.0040.01114.65
7.2.190.0110.00414.96
7.2.180.0040.01115.03
7.2.170.0040.00814.97
7.2.130.0150.01116.71
7.2.120.0120.01516.75
7.2.110.0240.00616.69
7.2.100.0150.01216.76
7.2.90.0200.00716.83
7.2.80.0190.01116.78
7.2.70.0210.00916.95
7.2.60.0140.01216.83
7.2.50.0250.00716.86
7.2.40.0210.00616.84
7.2.30.0170.00916.86
7.2.20.0200.00616.93
7.2.10.0160.01016.65
7.2.00.0090.00917.96
7.1.330.0060.00815.55
7.1.320.0040.00815.46
7.1.310.0080.00815.86
7.1.300.0100.00315.71
7.1.290.0000.00915.64
7.1.280.0000.00915.71
7.1.270.0090.00615.71
7.1.260.0100.00315.64
7.1.250.0160.00715.71
7.1.200.0080.00815.13
7.1.100.0000.01717.98
7.1.70.0000.00717.12
7.1.60.0000.02519.46
7.1.50.0060.00616.95
7.1.00.0030.07322.31
7.0.200.0100.00716.40
7.0.140.0100.06322.05
7.0.60.0000.04720.01
7.0.50.0100.05317.88
7.0.40.0070.07320.02
7.0.30.0300.06020.13
7.0.20.0200.04020.16
7.0.10.0030.09320.09
7.0.00.0070.06320.30
5.6.280.0070.07021.09
5.6.210.0100.06320.62
5.6.200.0130.08018.18
5.6.190.0000.05320.67
5.6.180.0200.05720.56
5.6.170.0430.06020.47
5.6.160.0030.04020.54
5.6.150.0030.05318.22
5.6.140.0200.06018.11
5.6.130.0070.04318.14
5.6.120.0100.04321.14
5.6.110.0130.06720.99
5.6.100.0000.04321.00
5.6.90.0000.09320.96
5.6.80.0070.07720.40
5.5.350.4070.04720.48
5.5.340.0070.03717.95
5.5.330.0070.09020.53
5.5.320.0270.05320.30
5.5.310.0270.07720.29
5.5.300.0130.08017.97
5.5.290.0100.07718.02
5.5.280.0070.08720.72
5.5.270.0100.07720.66
5.5.260.0030.04020.86
5.5.250.0100.05720.54
5.5.240.0130.07720.36
5.4.450.0170.05041.74
5.4.440.0830.05019.45
5.4.430.0670.05019.44
5.4.420.0230.04031.63
5.4.410.0230.04728.65
5.4.400.0270.04327.12
5.4.390.0630.03725.55
5.4.380.0500.05018.66
5.4.370.0500.05018.67
5.4.360.0170.05718.58
5.4.350.0330.05718.56
5.4.340.0230.05318.49
5.4.320.0060.03912.45
5.4.310.0070.05012.45
5.4.300.0090.04412.46
5.4.290.0110.03812.45
5.4.280.0070.03612.34
5.4.270.0080.04012.35
5.4.260.0110.05112.35
5.4.250.0060.05212.34
5.4.240.0080.04712.34
5.4.230.0070.05012.34
5.4.220.0050.04012.34
5.4.210.0090.03512.34
5.4.200.0060.03712.34
5.4.190.0090.03812.34
5.4.180.0070.04612.33
5.4.170.0080.03812.35
5.4.160.0060.04512.34
5.4.150.0080.03612.34
5.4.140.0060.04012.02
5.4.130.0060.03612.01
5.4.120.0040.03911.97
5.4.110.0070.03711.97
5.4.100.0090.04311.96
5.4.90.0120.04611.96
5.4.80.0100.05011.96
5.4.70.0080.05411.96
5.4.60.0100.04611.96
5.4.50.0090.03311.96
5.4.40.0100.03311.95
5.4.30.0110.04411.95
5.4.20.0070.05111.94
5.4.10.0080.03711.94
5.4.00.0060.03611.43
5.3.290.0060.04612.80
5.3.280.0110.04112.71
5.3.270.0030.05512.72
5.3.260.0080.05112.72
5.3.250.0090.04812.72
5.3.240.0130.04612.72
5.3.230.0110.05112.71
5.3.220.0090.04012.68
5.3.210.0070.05212.68
5.3.200.0110.04112.68
5.3.190.0090.04712.68
5.3.180.0120.04712.68
5.3.170.0100.04712.67
5.3.160.0080.05212.67
5.3.150.0090.04412.67
5.3.140.0040.05112.66
5.3.130.0060.04612.66
5.3.120.0080.04312.66
5.3.110.0040.04112.66
5.3.100.0100.04012.11
5.3.90.0080.04212.08
5.3.80.0160.03512.08
5.3.70.0100.03812.08
5.3.60.0070.04112.07
5.3.50.0090.04212.00
5.3.40.0060.04712.00
5.3.30.0090.03611.94
5.3.20.0080.03711.72
5.3.10.0060.04511.69
5.3.00.0060.04311.67
5.2.170.0070.0339.18
5.2.160.0030.0369.18
5.2.150.0060.0319.18
5.2.140.0030.0389.18
5.2.130.0040.0429.14
5.2.120.0050.0379.14
5.2.110.0040.0389.14
5.2.100.0060.0359.14
5.2.90.0080.0339.14
5.2.80.0090.0419.13
5.2.70.0070.0409.13
5.2.60.0030.0449.09
5.2.50.0080.0349.05
5.2.40.0050.0339.03
5.2.30.0060.0349.01
5.2.20.0100.0289.00
5.2.10.0060.0298.91
5.2.00.0030.0338.77
5.1.60.0060.0248.06
5.1.50.0040.0278.05
5.1.40.0060.0268.04
5.1.30.0040.0338.39
5.1.20.0080.0408.41
5.1.10.0040.0318.14
5.1.00.0080.0298.14
5.0.50.0080.0236.61
5.0.40.0070.0236.47
5.0.30.0050.0356.29
5.0.20.0070.0236.26
5.0.10.0060.0266.23
5.0.00.0100.0316.23
4.4.90.0030.0204.78
4.4.80.0040.0174.76
4.4.70.0020.0214.76
4.4.60.0050.0184.76
4.4.50.0030.0204.77
4.4.40.0040.0304.71
4.4.30.0050.0164.76
4.4.20.0060.0174.85
4.4.10.0040.0194.85
4.4.00.0040.0274.75
4.3.110.0070.0164.67
4.3.100.0030.0184.66
4.3.90.0040.0174.63
4.3.80.0030.0304.58
4.3.70.0070.0174.63
4.3.60.0060.0174.63
4.3.50.0010.0254.63
4.3.40.0030.0324.54
4.3.30.0040.0203.29
4.3.20.0030.0213.26
4.3.10.0030.0183.22
4.3.00.0030.02014.59

preferences:
41.21 ms | 401 KiB | 5 Q