homepage

This issue tracker has been migrated to GitHub , and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author serhiy.storchaka
Recipients ezio.melotti, lemburg, pitrou, serhiy.storchaka, vstinner
Date 2012年05月21日.22:19:25
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1337638770.26.0.783937266614.issue14874@psf.upfronthosting.co.za>
In-reply-to
Content
Charmap decoders are not as important as UTF decoders, but are still widely used. In Python 3.3 with PEP 393 they slowed down 4x. The proposed patch restores the performance.
Optimized only the most common case, when the decoder is specified by the UCS2 table with length >= 256. Map-based decoders translated to table-based. UCS1 tables widened to UCS2 by adding 257th fake characters.
Benchmark results:
 3.2 3.3(vanilla) 3.3(patched)
cp1251 'A'*10000 111 (+10%) 31 (+294%) 122
cp1251 '\xa0'*10000 111 (+8%) 29 (+314%) 120
cp1251 '\u0402'*10000 111 (+6%) 25 (+372%) 118
History
Date User Action Args
2012年05月21日 22:19:32serhiy.storchakasetrecipients: + serhiy.storchaka, lemburg, pitrou, vstinner, ezio.melotti
2012年05月21日 22:19:30serhiy.storchakasetmessageid: <1337638770.26.0.783937266614.issue14874@psf.upfronthosting.co.za>
2012年05月21日 22:19:29serhiy.storchakalinkissue14874 messages
2012年05月21日 22:19:29serhiy.storchakacreate

AltStyle によって変換されたページ (->オリジナル) /