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 eric.snow
Recipients eric.snow, lemburg, pitrou, serhiy.storchaka, vstinner
Date 2013-04-04.17:00:13
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1365094813.48.0.21403965853.issue17628@psf.upfronthosting.co.za>
In-reply-to
Content
> Marc-Andre Lemburg added the comment:
> Same here. The heuristic may work for short strings that easily fit
> into the CPU cache, but as soon as you use it on longer strings,
> this will result in much slower comparisons.

When testing both, would it help to test the end of the string before the beginning?  I'd expect that be more likely to leave the beginning in the cache for any subsequent memcmp() call.
History
Date User Action Args
2013-04-04 17:00:13eric.snowsetrecipients: + eric.snow, lemburg, pitrou, vstinner, serhiy.storchaka
2013-04-04 17:00:13eric.snowsetmessageid: <1365094813.48.0.21403965853.issue17628@psf.upfronthosting.co.za>
2013-04-04 17:00:13eric.snowlinkissue17628 messages
2013-04-04 17:00:13eric.snowcreate