GNU bug report logs - #21763
poor performance since grep 2.19 when comparing files with grep

Previous Next

Package: grep;

Reported by: "Bennett, Steve" <S.Bennett <at> lancaster.ac.uk>

Date: Mon, 26 Oct 2015 14:19:03 UTC

Severity: normal

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: "Bennett, Steve" <S.Bennett <at> lancaster.ac.uk>
To: Jim Meyering <jim <at> meyering.net>
Cc: "21763 <at> debbugs.gnu.org" <21763 <at> debbugs.gnu.org>
Subject: bug#21763: poor performance since grep 2.19 when comparing files with grep
Date: Tue, 27 Oct 2015 09:06:24 +0000
> Thank you for reporting that.
> Interesting: that progression (time vs. increasing N) is clearly quadratic
> or worse when using a multibyte locale, but is linear with LC_ALL=C.
> I suspect when you run "locale", it reports something like en_US.utf8.

Yes, it's a UTF8 locale. I hadn't thought of that and I should have realised,
given that that's what the main change was in grep v2.19.

> I.e., if you have no need for multi-byte matching, set LC_ALL=C, and that 
> idiom will be very quick, even for a million lines:

Yes, you're totally right there. Thanks!

> Currently, I am not planning even to investigate this for the imminent
> release.

I totally agree!

Cheers,

Steve.

This bug report was last modified 8 years and 201 days ago.

Previous Next


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