STINNER Victor added the comment:

> I suggest apply patch A to 3.3 as it fixes performance
> regression (2x) and is very simple.

ASCII and UTF-8 are the two most common codecs in the world, so it's justified 
to have heavily optimized encoders and decoders.

I don't know any application using UTF-32-LE or UTF-32-BE. So I don't want to 
waste Python memory/code size with a heavily optimized decoder. The patch A 
looks to be enough.

--

32 bit units is commonly used with wchar_t, but this format already has a fast 
decoder, PyUnicode_FromWideChar(), which uses memcpy() or 
_PyUnicode_CONVERT_BYTES().

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue14625>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to