GNU bug report logs -
#17229
[PATCH 2/2] grep: speed-up by using memchr() in Boyer-Moore searching
Previous Next
Reported by: Norihiro Tanaka <noritnk <at> kcn.ne.jp>
Date: Wed, 9 Apr 2014 13:56:02 UTC
Severity: normal
Tags: moreinfo, patch
Done: Norihiro Tanaka <noritnk <at> kcn.ne.jp>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
Paul Eggert wrote:
> This improves the performance quite a bit for the test case given in
> the ChangeLog entry. I also tested performance on Sparc Solaris 10,
> and memchr was a big win there.
You are right. I also ran the tests on Solaris 10 and HP-UX 11iv2.
memchr() was win on both machines. Especially on HP-UX 11iv2, memchr was
10x faster than delta1 searching.
By the way, could you also test below for master and original grep-2.18?
$ yes abcdabc | head -50000000 >../k
$ env LANG=C time -p src/grep abcd.bd ../k
Perhaps, later will be faster.
0001-grep-speed-up-by-replacing-incr-to-add-in-x86-and-x8.patch will fix
it. delta2 searching is higher cost than mind2 searching in original
grep-2.18. We need to reduce it for delta2 searching.
Norihiro
This bug report was last modified 11 years and 105 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.