|
From: | Paul Eggert |
Subject: | bug#17229: [PATCH 2/2] grep: speed-up by using memchr() in Boyer-Moore searching |
Date: | Sat, 26 Apr 2014 21:04:13 -0700 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.4.0 |
I attempted to suss out the performance improvements in that patch without using macros, and installed the attached changes. With these changes grep performs about as well as it does with that patch, on the benchmarks you mentioned that I tried (as before, I'm using the default optimization with GCC 4.9.0 x86-64 on an AMD Phenom II X4 910e). Quite possibly I've missed something, of course. The two "advance_*" constants used in the heuristics are guesses: I haven't measured rigorously to try to come up with good values.
0001-kwset-improve-performance-when-large-Boyer-Moore-key.patch
Description: Text document
0002-kwset-speed-up-by-using-memchr2.patch
Description: Text document
[Prev in Thread] | Current Thread | [Next in Thread] |