Subject: | no seek when block search ends at min |
Date: | Sat, 31 Aug 2013 10:32:49 +1000 |
To: | bug-Search-Dict [...] rt.cpan.org |
From: | Kevin Ryde <user42 [...] zip.com.au> |
As an idea for an optimization, if the block bsearch ends at the "min"
leg then there's no need to seek and read $min again to begin the linear
search -- the handle is already there.
This also has the happy effect of one less compare for end-at-min case.
For example the program duplicate-compare.pl below shows "513 cmp 514"
done twice, but just once after this change.
Message body is not shown because sender requested not to inline it.
Message body is not shown because sender requested not to inline it.
--
The sigfile one-line movie reviews series:
"Les Amants du Pont Neuf" -- a fine sequel to Les Amants du Pont Huit.