bug-grep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#17229: [PATCH 2/2] grep: speed-up by using memchr() in Boyer-Moore s


From: Norihiro Tanaka
Subject: bug#17229: [PATCH 2/2] grep: speed-up by using memchr() in Boyer-Moore searching
Date: Sun, 27 Apr 2014 16:57:21 +0900

Thanks for the improvement with memchr2().  It's very great!

Paul Eggert wrote:
> If there is a reason to use macros I'd like to see a patch that simply
> changes functions to macros without changing the algorithm, so that we
> can measure this effect separately from the algorithm change.

I tested with below.

  yes jjjjjjjjjjjjjjjjjjjj | head -10000000 >k
  env LC_ALL=C time -p src/grep kjjjjjjjjjjjjjjjjjjj k

The performance with the current master is as following.

    real 2.95       user 2.44       sys 0.45

After changes function to macros.

    real 1.09       user 0.59       sys 0.43

Could you try above cases?

Norihiro

Attachment: patch.txt
Description: Text document


reply via email to

[Prev in Thread] Current Thread [Next in Thread]