[KinoSearch] fast phrase matching [patch]
Nathan Kurz
nate at verse.com
Mon Sep 10 18:05:13 PDT 2007
Here's a stab at a faster phrase matcher. I haven't tested it on
anything other than an improved version of t/502-phrase-query and
Matthew's test case from the weekend. Looking at the object code
generates, I think should be considerably more efficient than the
current code, but it's also unlikely that the current code is ever a
bottleneck unless searching for 'and the' in a giant document.
I don't know that it makes sense as a patch right now. I won't be
offended if you decide that the current code is more reliable and
readable. I pulled out the DEBUG() and ASSERT() statements I used to
write it, which felt odd. I also convoluted it to agree with 'gcc
-pedantic', which I think definitely hurt readability. I think the
expanded tests for phrase offsets merit inclusion, though.
What is your opinion on C99 versus -pedantic? And how do you feel
about littering the code with assertions and environmentally
controlled debug statements?
Nathan Kurz
nate at verse.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: winnow_anchors.patch
Type: application/octet-stream
Size: 8914 bytes
Desc: not available
Url : http://rectangular.com/pipermail/kinosearch/attachments/20070910/79f710e0/attachment-0001.obj
-------------- next part --------------
_______________________________________________
KinoSearch mailing list
KinoSearch at rectangular.com
http://www.rectangular.com/mailman/listinfo/kinosearch
More information about the kinosearch
mailing list