Change prefix search from O(N*M) to O(NlogM). The previous code

linearly merged the doclists, so as the accumulated list got large,
things got slow (the M term, a fucntion of the number of documents in
the index).  This change does pairwise merges until a single doclist
remains.  A test search of 't*' against a database of RFC text
improves from 1m16s to 4.75s. (CVS 4599)

FossilOrigin-Name: feef1b15d645d638b4a05742f214b0445fa7e176
This commit is contained in:
shess
2007-12-07 23:47:53 +00:00
parent e5fe690d75
commit b6a75606ed
3 changed files with 129 additions and 26 deletions
+1 -1
View File
@@ -1 +1 @@
c9eb65912f61ce0a6b66fe253652a1827e46b12a
feef1b15d645d638b4a05742f214b0445fa7e176