GNU bug report logs - #16232
[PATCH] grep: make --ignore-case (-i) faster (sometimes 10x) in multibyte locales

Previous Next

Package: grep;

Reported by: Jim Meyering <jim <at> meyering.net>

Date: Mon, 23 Dec 2013 22:40:02 UTC

Severity: normal

Tags: patch

Done: Paul Eggert <eggert <at> cs.ucla.edu>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Jim Meyering <jim <at> meyering.net>
To: Eric Blake <eblake <at> redhat.com>
Cc: 16232 <16232 <at> debbugs.gnu.org>
Subject: bug#16232: [PATCH] grep: make --ignore-case (-i) faster (sometimes 10x) in multibyte locales
Date: Tue, 7 Jan 2014 19:56:21 -0800
[Message part 1 (text/plain, inline)]
On Mon, Dec 23, 2013 at 3:54 PM, Jim Meyering <jim <at> meyering.net> wrote:
...
> Thanks for dotting those 'i's.  While there is no risk of buffer
> overrun, there would definitely be a problem with the tr_TR locale.
> I will resolve it by removing the isascii check and performing
> multibyte case conversion to form each [cC] pair.  Of course,
> that will mean removing the "4 * byte-length-of-search-string"
> buffer size limitation.
>
> I will also add tests based on your examples.

Here is the improved patch.
[k.txt (text/plain, attachment)]

This bug report was last modified 11 years and 82 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.