3v4l.org

run code in 300+ PHP versions simultaneously
<?php $exclude = 'BASE64,UUENCODE,HTML-ENTITIES,Quoted-Printable,' . '7bit,8bit,pass,wchar,byte2be,byte2le,byte4be,byte4le,' . 'UCS-4,UCS-4BE,UCS-4LE,UCS-2,UCS-2BE,UCS-2LE'; $prio = [ 'UTF-8', 'ISO-8859-1', 'ISO-8859-2', 'ISO-8859-3', 'ISO-8859-4', 'ISO-8859-5', 'ISO-8859-6', 'ISO-8859-7', 'ISO-8859-8', 'ISO-8859-9', 'ISO-8859-10', 'ISO-8859-13', 'ISO-8859-14', 'ISO-8859-15', 'ISO-8859-16', 'WINDOWS-1252', 'WINDOWS-1251', 'WINDOWS-1254', 'EUC-JP', 'EUC-TW', 'KOI8-R', 'BIG-5', 'ISO-2022-KR', 'ISO-2022-JP', 'GB18030', ]; $all_encodings = array_diff(mb_list_encodings(), explode(',', $exclude)); $encodings = array_unique(array_merge($prio, $all_encodings)); $test = 'Iksi' . chr(241) . 'ski'; echo mb_detect_encoding($test, $encodings);

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.70.0140.00716.75
8.3.60.0120.01216.75
8.3.50.0100.00320.18
8.3.40.0100.00719.33
8.3.30.0120.00318.99
8.3.20.0040.00424.18
8.3.10.0080.00024.66
8.3.00.0000.00726.16
8.2.190.0120.00416.88
8.2.180.0040.01525.92
8.2.170.0090.00619.16
8.2.160.0130.00622.96
8.2.150.0080.00025.66
8.2.140.0070.00024.66
8.2.130.0070.00026.16
8.2.120.0050.00521.14
8.2.110.0000.01021.13
8.2.100.0040.00718.16
8.2.90.0000.01017.91
8.2.80.0050.00319.39
8.2.70.0030.00517.88
8.2.60.0000.00817.75
8.2.50.0000.00817.88
8.2.40.0030.00518.00
8.2.30.0000.00818.06
8.2.20.0020.00519.66
8.2.10.0000.00717.80
8.2.00.0040.00419.37
8.1.280.0070.01125.92
8.1.270.0040.00423.99
8.1.260.0030.00526.35
8.1.250.0040.00428.09
8.1.240.0060.00322.26
8.1.230.0080.00421.22
8.1.220.0050.00318.04
8.1.210.0030.00618.78
8.1.200.0060.00317.60
8.1.190.0050.00317.78
8.1.180.0080.00018.10
8.1.170.0030.00517.78
8.1.160.0000.00919.12
8.1.150.0000.00818.89
8.1.140.0000.00917.55
8.1.130.0000.00717.57
8.1.120.0040.00817.72
8.1.110.0040.00417.66
8.1.100.0000.00817.66
8.1.90.0040.00417.54
8.1.80.0100.00017.68
8.1.70.0000.00817.69
8.1.60.0080.00017.67
8.1.50.0050.00517.60
8.1.40.0000.00917.60
8.1.30.0050.00517.73
8.1.20.0080.00317.88
8.1.10.0060.00317.73
8.1.00.0110.00017.75
8.0.300.0040.00420.15
8.0.290.0000.01116.87
8.0.280.0070.00018.11
8.0.270.0000.00716.91
8.0.260.0070.00016.90
8.0.250.0000.00717.11
8.0.240.0020.00517.11
8.0.230.0030.00316.92
8.0.220.0000.00716.98
8.0.210.0000.00716.97
8.0.200.0030.00317.05
8.0.190.0040.00417.05
8.0.180.0040.00417.04
8.0.170.0060.00316.88
8.0.160.0040.00416.95
8.0.150.0000.00716.98
8.0.140.0060.00616.80
8.0.130.0070.00013.33
8.0.120.0070.00313.33
8.0.110.0080.00413.43
8.0.100.0090.00413.31
8.0.90.0130.00013.40
8.0.80.0080.00413.37
8.0.70.0040.00913.36
8.0.60.0090.00413.42
8.0.50.0070.00713.42
8.0.30.0060.00613.36
8.0.20.0080.00413.49
8.0.10.0060.00613.33
8.0.00.0080.00013.39
7.4.330.0050.00015.55
7.4.320.0050.00216.64
7.4.300.0000.00716.67
7.4.290.0030.00616.55
7.4.280.0050.00316.43
7.4.270.0000.00716.46
7.4.260.0050.00013.33
7.4.250.0060.00613.32
7.4.240.0100.00313.36
7.4.230.0130.00013.29
7.4.220.0070.00713.34
7.4.210.0050.00513.35
7.4.200.0110.00013.28
7.4.190.0040.00713.45
7.4.180.0100.00313.46
7.4.160.0080.00313.38
7.4.150.0070.00513.32
7.4.140.0090.00013.31
7.4.130.0090.00313.29
7.4.120.0050.00513.30
7.4.110.0140.00013.34
7.4.100.0100.00313.51
7.4.90.0070.00713.38
7.4.80.0080.00413.30
7.4.70.0090.00313.37
7.4.60.0100.00313.37
7.4.50.0110.00313.40
7.4.40.0110.00213.26
7.4.30.0090.00413.34
7.4.20.0090.00213.21
7.4.10.0080.00413.31
7.4.00.0040.00713.31
7.3.330.0000.00716.30
7.3.320.0070.00313.08
7.3.310.0120.00013.04
7.3.300.0120.00013.10
7.3.290.0110.00313.09
7.3.280.0140.00013.09
7.3.270.0110.00313.00
7.3.260.0130.00013.06
7.3.250.0080.00613.15
7.3.240.0070.00712.95
7.3.230.0040.00913.23
7.3.220.0120.00212.93
7.3.210.0070.00712.97
7.3.200.0100.00012.92
7.3.190.0090.00512.93
7.3.180.0130.00313.07
7.3.170.0110.00212.97
7.3.160.0130.00012.89
7.3.150.0150.00012.95
7.3.140.0070.00713.19
7.3.130.0130.00013.04
7.3.120.0090.00412.96
7.3.110.0090.00612.96
7.3.100.0100.00512.98
7.3.90.0060.00813.30
7.3.80.0060.00613.10
7.3.70.0080.00313.26
7.3.60.0120.00013.20
7.3.50.0070.00313.26
7.3.40.0040.00713.33
7.3.30.0060.00613.38
7.3.20.0110.00015.09
7.3.10.0040.00715.00
7.3.00.0070.00515.02

preferences:
27.8 ms | 401 KiB | 5 Q