[PATCH v2] speedup strcoll by using strdiff
Leonhard Holz
leonhard.holz@web.de
Sun Apr 5 12:51:00 GMT 2015
Am 03.04.2015 um 17:15 schrieb OndÅej BÃlka:
> On Fri, Mar 13, 2015 at 07:34:33AM +0100, Leonhard Holz wrote:
>> This patch uses strdiff to skip over equal prefixes in strcoll. This
>> is implemented for 8-bit character sets and UTF-8.
>>
> Almost ok for me.
>
> I would rather do detection in setlocale by setting new value so you
> could use say:
>
> current->values[_NL_ITEM_INDEX (_NL_COLLATE_ENCODING_TYPE)].word;
>
> Now it would be faster unless you have long running application that
> uses lot of locales. Then linear browsing of list could be bottleneck.
>
That did work. The v3 patch follows.
> Second request is moving strcoll to separate file due optimized
> implementations.
Did you mean strdiff?
More information about the Libc-alpha
mailing list