3v4l.org

run code in 300+ PHP versions simultaneously
<?php $string = 'Hello "world". [start]this is a "mark"[end]. It should work with [start]"several" "marks"[end]'; $regex = '/(?s)"(?=((?!\[start\]).)*\[end\])/'; $replace = '&quot;'; echo preg_replace($regex, $replace, $string);

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.5.10.0110.00720.27
8.5.00.0110.01120.17
8.4.150.0030.00014.05
8.4.140.0120.00917.93
8.4.130.0060.00317.75
8.4.120.0120.00822.26
8.4.110.0130.00720.84
8.4.100.0050.00418.89
8.4.90.0120.01020.63
8.4.80.0110.00918.88
8.4.70.0140.00618.27
8.4.60.0130.00618.71
8.4.50.0160.00519.86
8.4.40.0100.00724.19
8.4.30.0070.01322.60
8.4.20.0040.01217.67
8.4.10.0000.00919.53
8.3.280.0080.01220.32
8.3.270.0140.00816.61
8.3.260.0110.00916.58
8.3.250.0110.00718.55
8.3.240.0120.00717.00
8.3.230.0130.00516.30
8.3.220.0060.00218.73
8.3.210.0100.00816.61
8.3.200.0050.00416.79
8.3.190.0120.00618.86
8.3.180.0080.01216.55
8.3.170.0140.00416.50
8.3.160.0040.00417.03
8.3.150.0040.00420.69
8.3.140.0090.00918.83
8.3.130.0090.00016.72
8.3.120.0030.00618.70
8.3.110.0040.00420.94
8.3.100.0050.00324.06
8.3.90.0030.00526.77
8.3.80.0090.00018.30
8.3.70.0070.01118.56
8.3.60.0130.01018.56
8.3.50.0150.00322.85
8.3.40.0110.00319.02
8.3.30.0050.01018.63
8.3.20.0080.00020.21
8.3.10.0040.00421.91
8.3.00.0040.00419.54
8.2.290.0100.00820.20
8.2.280.0110.00820.28
8.2.270.0120.00617.00
8.2.260.0000.00816.98
8.2.250.0080.00416.55
8.2.240.0040.00417.23
8.2.230.0080.00022.58
8.2.220.0100.00037.54
8.2.210.0040.00426.77
8.2.200.0060.00316.50
8.2.190.0080.00816.58
8.2.180.0150.00016.63
8.2.170.0070.00722.96
8.2.160.0030.01721.00
8.2.150.0050.00324.18
8.2.140.0050.00324.66
8.2.130.0050.00326.16
8.2.120.0080.00021.16
8.2.110.0000.00920.46
8.2.100.0070.00419.95
8.2.90.0080.00019.23
8.2.80.0000.00817.97
8.2.70.0090.00017.75
8.2.60.0040.00417.63
8.2.50.0080.00018.10
8.2.40.0040.00422.38
8.2.30.0070.00019.27
8.2.20.0040.00417.71
8.2.10.0040.00417.89
8.2.00.0040.00418.00
8.1.330.0110.00821.79
8.1.320.0130.01116.30
8.1.310.0080.00016.78
8.1.300.0100.00018.02
8.1.290.0060.00330.84
8.1.280.0100.00725.92
8.1.270.0040.00424.66
8.1.260.0080.01126.35
8.1.250.0070.00028.09
8.1.240.0130.01018.59
8.1.230.0060.00620.99
8.1.220.0040.00417.74
8.1.210.0090.00018.77
8.1.200.0000.00817.35
8.1.190.0060.00317.36
8.1.180.0040.00418.10
8.1.170.0030.00518.61
8.1.160.0000.00722.17
8.1.150.0050.00220.55
8.1.140.0040.00419.44
8.1.130.0040.00417.57
8.1.120.0040.00417.52
8.1.110.0030.00617.47
8.1.100.0030.00617.51
8.1.90.0050.00517.57
8.1.80.0040.00417.57
8.1.70.0000.00717.44
8.1.60.0050.00317.68
8.1.50.0080.00017.59
8.1.40.0080.00317.46
8.1.30.0040.00417.65
8.1.20.0040.00417.69
8.1.10.0040.00417.72
8.1.00.0040.00417.50
8.0.300.0000.00718.77
8.0.290.0070.00016.75
8.0.280.0030.00318.35
8.0.270.0070.00017.19
8.0.260.0030.00317.27
8.0.250.0060.00017.12
8.0.240.0000.00817.02
8.0.230.0070.00017.06
8.0.220.0070.00016.92
8.0.210.0000.00716.97
8.0.200.0070.00016.89
8.0.190.0030.00317.04
8.0.180.0000.00716.94
8.0.170.0000.00717.04
8.0.160.0030.00316.98
8.0.150.0040.00416.93
8.0.140.0070.00016.96
8.0.130.0030.00313.43
8.0.120.0040.00416.93
8.0.110.0000.00716.96
8.0.100.0080.00016.85
8.0.90.0040.00416.90
8.0.80.0060.01816.91
8.0.70.0000.00816.93
8.0.60.0030.00516.84
8.0.50.0040.00416.83
8.0.30.0140.00516.93
8.0.20.0070.01117.40
8.0.10.0030.00617.09
8.0.00.0060.01316.81
7.4.330.0020.00215.16
7.4.320.0030.00316.66
7.4.300.0030.00316.75
7.4.290.0070.00016.67
7.4.280.0080.00016.69
7.4.270.0030.00316.63
7.4.260.0070.00016.67
7.4.250.0030.00316.69
7.4.240.0070.00016.72
7.4.230.0070.00016.68
7.4.220.0180.01416.68
7.4.210.0040.01116.76
7.4.200.0070.00016.56
7.4.150.0160.00317.40
7.4.140.0100.01117.86
7.4.130.0130.00616.73
7.4.120.0070.01216.81
7.4.110.0120.00916.75
7.4.100.0030.01516.64
7.4.90.0060.01516.62
7.4.80.0090.01019.39
7.4.70.0100.00616.51
7.4.60.0110.01116.57
7.4.50.0070.00716.47
7.4.40.0080.00816.65
7.4.30.0070.01116.73
7.4.00.0140.00315.10
7.3.330.0040.00313.03
7.3.320.0030.00313.11
7.3.310.0020.00516.35
7.3.300.0050.00216.24
7.3.290.0030.00316.24
7.3.280.0100.00816.28
7.3.270.0130.00317.40
7.3.260.0160.00916.59
7.3.250.0090.01316.50
7.3.240.0150.00516.33
7.3.230.0060.01616.39
7.3.210.0180.00016.34
7.3.200.0100.00716.36
7.3.190.0060.00916.63
7.3.180.0090.00616.56
7.3.170.0200.00016.58
7.3.160.0170.00016.40
7.2.330.0100.00616.70
7.2.320.0050.01116.70
7.2.310.0080.00916.62
7.2.300.0100.00716.63
7.2.290.0060.01216.66
7.2.60.0040.00416.75
7.2.00.0040.01219.45
7.1.200.0000.01415.91
7.1.70.0040.00417.17
7.1.60.0000.01119.75
7.1.00.0000.08322.33
7.0.200.0050.00317.01
7.0.90.0000.07019.98
7.0.80.0130.05719.98
7.0.70.0100.06019.99
7.0.60.0070.06020.01
7.0.50.0270.04320.36
7.0.40.0130.05720.44
7.0.30.0170.06020.34
7.0.20.0130.06020.19
7.0.10.0200.05320.23
7.0.00.0200.06320.32
5.6.240.0200.05720.62
5.6.230.0130.05720.54
5.6.220.0100.06020.62
5.6.210.0200.05020.71
5.6.200.0170.06321.05
5.6.190.0070.06721.02
5.6.180.0200.05321.06
5.6.170.0270.04321.11
5.6.160.0170.05321.01
5.6.150.0170.05321.10
5.6.140.0230.05721.18
5.6.130.0100.06321.07
5.6.120.0100.06321.18
5.6.110.0130.06021.04
5.6.100.0230.04721.02
5.6.90.0170.07321.09
5.6.80.0170.05720.53
5.6.70.0270.04720.48
5.6.60.0130.07720.38
5.6.50.0330.05320.35
5.6.40.0130.07720.44
5.6.30.0070.07020.39
5.6.20.0070.05720.40
5.6.10.0230.04320.47
5.6.00.0070.06020.41

preferences:
39.57 ms | 403 KiB | 5 Q