3v4l.org

run code in 300+ PHP versions simultaneously
<?php $result = "°Freen\x18 ew°\x90ɮ\xc2"; //$result = trim($result,"\xc2"/*"\xa0"*/); //echo preg_replace('#[\x00-\x1F\x7F-\x9F]#S', '', $result); echo preg_replace('~[\x{0000}-\x{001F}\x{007F}-\x{00a0}]~', '', $result); /* //reject overly long 2 byte sequences, as well as characters above U+10000 and replace with ? $result= preg_replace('/[\x00-\x08\x10\x0B\x0C\x0E-\x19\x7F]'. '|[\x00-\x7F][\x80-\xBF]+'. '|([\xC0\xC1]|[\xF0-\xFF])[\x80-\xBF]*'. '|[\xC2-\xDF]((?![\x80-\xBF])|[\x80-\xBF]{2,})'. '|[\xE0-\xEF](([\x80-\xBF](?![\x80-\xBF]))|(?![\x80-\xBF]{2})|[\x80-\xBF]{3,})/S', '', $result ); 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.0150.00018.56
8.3.50.0090.01021.14
8.3.40.0060.01218.97
8.3.30.0070.00718.79
8.3.20.0050.00318.85
8.3.10.0050.00321.05
8.3.00.0040.00421.71
8.2.180.0120.00616.63
8.2.170.0120.00322.96
8.2.160.0100.00720.52
8.2.150.0040.00424.18
8.2.140.0080.00024.66
8.2.130.0000.00826.16
8.2.120.0070.00021.17
8.2.110.0070.00420.16
8.2.100.0060.00617.84
8.2.90.0070.00019.23
8.2.80.0000.00817.97
8.2.70.0040.00417.75
8.2.60.0000.00817.80
8.2.50.0080.00018.07
8.2.40.0080.00018.16
8.2.30.0050.00321.29
8.2.20.0040.00417.81
8.2.10.0050.00217.78
8.2.00.0050.00217.84
8.1.280.0110.00425.92
8.1.270.0030.00723.99
8.1.260.0120.00626.35
8.1.250.0040.00428.09
8.1.240.0070.00322.50
8.1.230.0070.00420.95
8.1.220.0060.00318.77
8.1.210.0050.00318.89
8.1.200.0030.00617.36
8.1.190.0040.00417.39
8.1.180.0040.00418.10
8.1.170.0030.00618.64
8.1.160.0000.00718.91
8.1.150.0000.00818.73
8.1.140.0040.00417.54
8.1.130.0000.00717.91
8.1.120.0070.00017.44
8.1.110.0040.00417.57
8.1.100.0000.00717.50
8.1.90.0000.00717.57
8.1.80.0000.00817.55
8.1.70.0030.00617.58
8.1.60.0090.00017.60
8.1.50.0050.00317.52
8.1.40.0000.00817.60
8.1.30.0030.00517.73
8.1.20.0040.00417.75
8.1.10.0000.00717.71
8.1.00.0040.00717.70
8.0.300.0000.00720.02
8.0.290.0080.00017.16
8.0.280.0000.00818.54
8.0.270.0070.00417.21
8.0.260.0090.00016.94
8.0.250.0040.00417.02
8.0.240.0090.00017.02
8.0.230.0030.00317.11
8.0.220.0070.00016.86
8.0.210.0030.00316.97
8.0.200.0040.00416.94
8.0.190.0000.00817.04
8.0.180.0000.00717.01
8.0.170.0040.00416.89
8.0.160.0050.00316.94
8.0.150.0000.00716.84
8.0.140.0000.00816.98
8.0.130.0000.00513.45
8.0.120.0000.00716.97
8.0.110.0060.00316.93
8.0.100.0070.00017.00
8.0.90.0040.00416.98
8.0.80.0040.01416.97
8.0.70.0080.00016.79
8.0.60.0000.00816.86
8.0.50.0050.00317.02
8.0.30.0090.01016.98
8.0.20.0040.01417.40
8.0.10.0040.00417.08
8.0.00.0090.00816.99
7.4.330.0050.00014.96
7.4.320.0060.00016.67
7.4.300.0030.00316.72
7.4.290.0070.00016.73
7.4.280.0030.00316.71
7.4.270.0050.00316.78
7.4.260.0050.00013.50
7.4.250.0060.00316.67
7.4.240.0000.00716.69
7.4.230.0030.00316.58
7.4.220.0100.00716.82
7.4.210.0080.00816.77
7.4.200.0050.00216.55
7.4.190.0050.00316.71
7.4.160.0120.00316.52
7.4.150.0200.00617.40
7.4.140.0110.00617.86
7.4.130.0080.01116.60
7.4.120.0140.00516.63
7.4.110.0080.00816.73
7.4.100.0170.00016.68
7.4.90.0060.01216.50
7.4.80.0120.00619.39
7.4.70.0100.00716.65
7.4.60.0040.01116.63
7.4.50.0030.00616.70
7.4.40.0080.00822.77
7.4.30.0070.01016.63
7.4.10.0100.00615.16
7.4.00.0110.00515.12
7.3.330.0020.00213.17
7.3.320.0020.00213.19
7.3.310.0070.00016.23
7.3.300.0030.00316.24
7.3.290.0100.01016.23
7.3.280.0090.00716.29
7.3.270.0090.00917.40
7.3.260.0080.01418.24
7.3.250.0090.00916.36
7.3.240.0120.00916.60
7.3.230.0030.01316.39
7.3.210.0080.00816.56
7.3.200.0140.00819.39
7.3.190.0120.01016.64
7.3.180.0040.01216.36
7.3.170.0160.00616.58
7.3.160.0060.00916.52
7.3.130.0060.01215.02
7.3.120.0090.00614.72
7.3.110.0090.00814.42
7.3.100.0100.00715.07
7.3.90.0070.00714.71
7.3.80.0030.01315.19
7.3.70.0030.01014.86
7.3.60.0030.01314.73
7.3.50.0060.00314.95
7.3.40.0070.00714.48
7.3.30.0060.00914.53
7.3.20.0130.00316.55
7.3.10.0040.01116.68
7.3.00.0030.01316.76
7.2.330.0160.00316.77
7.2.320.0190.00016.66
7.2.310.0090.01016.71
7.2.300.0060.00916.71
7.2.290.0100.00716.57
7.2.260.0030.01715.10
7.2.250.0070.01314.98
7.2.240.0070.00715.16
7.2.230.0040.00915.16
7.2.220.0070.01115.19
7.2.210.0040.01114.96
7.2.200.0060.00915.31
7.2.190.0050.00514.98
7.2.180.0120.00614.82
7.2.170.0040.00715.02
7.2.160.0090.00615.12
7.2.150.0030.00716.89
7.2.140.0140.00316.96
7.2.130.0100.00716.97
7.2.120.0080.00416.65
7.2.110.0040.01217.09
7.2.100.0030.01316.77
7.2.90.0040.01117.11
7.2.80.0000.01216.93
7.2.70.0120.00616.63
7.2.60.0080.00516.85
7.2.50.0060.01117.04
7.2.40.0060.00617.01
7.2.30.0000.02016.96
7.2.20.0030.01617.07
7.2.10.0060.01316.90
7.2.00.0000.01416.93
7.1.330.0030.01016.11
7.1.320.0030.01415.72
7.1.310.0030.00815.89
7.1.300.0090.00615.61
7.1.290.0070.00815.58
7.1.280.0030.00615.92
7.1.270.0030.01215.89
7.1.260.0110.00615.77
7.1.250.0030.00915.92
7.1.240.0030.00615.86
7.1.230.0060.00915.96
7.1.220.0060.00815.79
7.1.210.0070.00715.60
7.1.200.0070.00715.71
7.1.190.0100.00315.71
7.1.180.0070.01015.88
7.1.170.0000.01315.99
7.1.160.0030.00715.97
7.1.150.0030.01015.94
7.1.140.0120.00615.99
7.1.130.0090.00315.70
7.1.120.0090.00615.93
7.1.110.0070.01115.96
7.1.100.0060.01015.87
7.1.90.0030.01315.91
7.1.80.0070.00315.99
7.1.70.0020.01216.44
7.1.60.0090.01217.69
7.1.50.0150.01125.50
7.1.40.0000.00815.90
7.1.30.0070.00715.63
7.1.20.0060.00615.53
7.1.10.0080.00415.89
7.1.00.0040.02019.18
7.0.330.0030.00715.39
7.0.320.0000.01215.32
7.0.310.0060.00615.13
7.0.300.0030.00615.58
7.0.290.0070.00715.05
7.0.280.0070.01015.35
7.0.270.0120.00315.38
7.0.260.0030.01015.25
7.0.250.0070.00815.61
7.0.240.0060.00315.70
7.0.230.0070.00715.63
7.0.220.0040.01115.68
7.0.210.0030.00915.46
7.0.200.0020.00516.09
7.0.190.0100.00315.70
7.0.180.0070.00015.65
7.0.170.0040.00715.60
7.0.160.0040.00415.46
7.0.150.0000.01315.63
7.0.140.0030.04418.68
7.0.130.0090.00615.60
7.0.120.0040.00715.67
7.0.110.0030.01315.77
7.0.100.0110.00615.38
7.0.90.0100.00715.60
7.0.80.0070.00315.77
7.0.70.0000.01415.41
7.0.60.0050.04017.65
7.0.50.0070.04216.80
7.0.40.0050.04716.78
7.0.30.0170.03816.78
7.0.20.0100.05016.77
7.0.10.0050.02916.71
7.0.00.0050.04016.84
5.6.400.0070.00714.30
5.6.390.0070.00714.34
5.6.380.0090.00014.32
5.6.370.0060.00614.33
5.6.360.0060.00614.34
5.6.350.0120.00314.74
5.6.340.0030.01314.42
5.6.330.0070.00614.38
5.6.320.0060.00314.54
5.6.310.0000.01514.29
5.6.300.0000.01314.38
5.6.290.0040.01114.32
5.6.280.0050.03817.79
5.6.270.0030.00714.05
5.6.260.0060.00914.41
5.6.250.0030.01014.39
5.6.240.0000.01714.24
5.6.230.0060.00614.25
5.6.220.0130.00314.20
5.6.210.0050.02517.37
5.6.200.0050.04516.40
5.6.190.0040.02717.45
5.6.180.0120.03417.50
5.6.170.0130.03017.40
5.6.160.0110.02517.54
5.6.150.0030.05016.35
5.6.140.0060.04316.22
5.6.130.0030.02616.27
5.6.120.0080.02317.79
5.6.110.0050.02617.59
5.6.100.0080.03417.67
5.6.90.0150.04017.68
5.6.80.0050.04717.43
5.6.70.0150.04117.24
5.6.60.0110.00314.15
5.6.50.0070.00614.36
5.6.40.0060.00914.22
5.6.30.0100.00314.13
5.6.20.0030.00614.45
5.6.10.0040.01114.28
5.6.00.0030.01314.25
5.5.380.0030.00914.18
5.5.370.0090.00613.99
5.5.360.0060.00914.10
5.5.350.0210.03817.30
5.5.340.0030.03116.05
5.5.330.0070.04417.42
5.5.320.0120.02517.10
5.5.310.0210.03317.28
5.5.300.0080.04116.04
5.5.290.0080.02216.12
5.5.280.0100.02917.50
5.5.270.0090.02017.52
5.5.260.0030.03317.65
5.5.250.0090.04317.39
5.5.240.0130.03817.08
5.5.230.0000.01414.30
5.5.220.0120.00314.17
5.5.210.0090.00614.42
5.5.200.0090.00914.20
5.5.190.0090.00314.03
5.5.180.0060.00614.30
5.5.170.0080.00814.20
5.5.160.0000.01514.27
5.5.150.0060.00614.21
5.5.140.0050.00814.14
5.5.130.0060.00914.22
5.5.120.0100.00713.85
5.5.110.0030.00914.18
5.5.100.0040.01114.01
5.5.90.0070.01014.24
5.5.80.0030.00614.12
5.5.70.0060.00314.02
5.5.60.0040.00814.12
5.5.50.0000.01414.20
5.5.40.0000.01014.30
5.5.30.0120.00014.21
5.5.20.0000.01014.31
5.5.10.0070.00714.34
5.5.00.0060.01014.12
5.4.450.1260.02815.29
5.4.440.0980.02015.10
5.4.430.0970.01715.28
5.4.420.1100.02815.35
5.4.410.0880.02215.13
5.4.400.0950.02214.96
5.4.390.0360.02315.09
5.4.380.0050.02515.02
5.4.370.0020.02215.07
5.4.360.0360.02014.92
5.4.350.0780.02215.10
5.4.340.1030.02015.01
5.4.330.0100.00011.01
5.4.320.0520.02015.09
5.4.310.1070.02514.92
5.4.300.1050.02815.17
5.4.290.1050.02315.15
5.4.280.0950.02014.90
5.4.270.1000.02714.92
5.4.260.0880.02014.96
5.4.250.0980.03015.00
5.4.240.1070.02715.07
5.4.230.1030.02615.06
5.4.220.1030.02115.12
5.4.210.1160.02115.02
5.4.200.1050.02315.04
5.4.190.1070.02515.07
5.4.180.0980.02515.15
5.4.170.0970.02514.93
5.4.160.1090.02415.06
5.4.150.1080.02515.08
5.4.140.1090.02413.84
5.4.130.1040.02413.67
5.4.120.0920.01813.75
5.4.110.1070.02513.57
5.4.100.1080.02313.67
5.4.90.1050.02013.65
5.4.80.0930.02213.48
5.4.70.1040.02913.67
5.4.60.1120.01813.55
5.4.50.1080.02313.55
5.4.40.1060.02413.76
5.4.30.1080.02113.67
5.4.20.1080.02213.70
5.4.10.1150.02613.64
5.4.00.0970.01813.51
5.3.290.0920.02212.71
5.3.280.0950.02312.68
5.3.270.0950.02212.73
5.3.260.1120.02912.68
5.3.250.0980.01812.80
5.3.240.1150.02212.73
5.3.230.1050.02412.69
5.3.220.0720.02712.66
5.3.210.0100.02512.66
5.3.200.0100.01812.66
5.3.190.0630.03012.66
5.3.180.0670.02012.66
5.3.170.0980.02012.66
5.3.160.1080.02312.76
5.3.150.0980.01812.66
5.3.140.1020.01512.65
5.3.130.1000.02512.71
5.3.120.1180.02212.67
5.3.110.1030.02812.71
5.3.100.1040.02312.40
5.3.90.1110.02112.39
5.3.80.1070.01712.51
5.3.70.1080.01712.38
5.3.60.1060.02512.46
5.3.50.0920.02012.36
5.3.40.1070.02412.47
5.3.30.0980.02612.38
5.3.20.1100.02412.32
5.3.10.1000.02112.25
5.3.00.1050.02412.23
5.2.170.1800.03311.52
5.2.160.1800.03711.52
5.2.150.1570.03011.52
5.2.140.1770.03311.52
5.2.130.1730.03011.52
5.2.120.1530.02311.52
5.2.110.1800.03011.52
5.2.100.1600.02011.52
5.2.90.1730.03311.52
5.2.80.1730.03311.52
5.2.70.1800.03711.52
5.2.60.1770.03311.52
5.2.50.1730.03311.52
5.2.40.1530.02311.52
5.2.30.0070.04011.52
5.2.20.0000.06311.52
5.2.10.0000.03311.52
5.2.00.0070.03011.52
5.1.60.0900.04311.52
5.1.50.1230.02711.52
5.1.40.1400.03011.52
5.1.30.1470.03011.52
5.1.20.1370.02711.52
5.1.10.1430.03011.52
5.1.00.1270.02311.52
5.0.50.0400.04011.52
5.0.40.0600.02011.52
5.0.30.0630.03011.52
5.0.20.0600.02011.52
5.0.10.0600.02011.52
5.0.00.0700.03311.52
4.4.90.0800.02011.52
4.4.80.0630.01711.52
4.4.70.0570.01711.52
4.4.60.0670.01711.52
4.4.50.0630.01011.52
4.4.40.0270.04711.52
4.4.30.0000.01711.52
4.4.20.0070.03011.52
4.4.10.0000.02311.52
4.4.00.0030.03711.52
4.3.110.0000.04311.52
4.3.100.0030.01311.52
4.3.90.0030.01711.52
4.3.80.0170.02311.52
4.3.70.0600.01311.52
4.3.60.0770.01311.52
4.3.50.0670.02311.52
4.3.40.0730.02711.52
4.3.30.0400.02011.52
4.3.20.0430.02711.52
4.3.10.0370.02011.52
4.3.00.0370.01711.52

preferences:
38.96 ms | 401 KiB | 5 Q