Pass doclen and unique_terms down from PostListTree
commit2d6995c323f1c6706d76a34a3b314beb8a730662
authorOlly Betts <olly@survex.com>
Wed, 13 Dec 2017 22:26:58 +0000 (14 11:26 +1300)
committerOlly Betts <olly@survex.com>
Wed, 13 Dec 2017 22:26:58 +0000 (14 11:26 +1300)
tree10b1b094086f02125dfcc387a9030c875503670a
parentdfa7aa92f830af63e4d362f11f5f429a782f58fe
Pass doclen and unique_terms down from PostListTree

Previously postlists called down the tree to the leaves to fetch
these stats to use when calculating weights.  In the flint backend
and before, the postlists stored the document length which is why we
implemented it this way, but in chert we changed that to store a single
list of document lengths (which is more update-friendly and needs less
space because we don't redundantly store each document length many
times).

Now we no longer need to support flint-style storage, it makes more
sense to pass down these stats from PostListTree, with a mechanism for
explicitly fetching them from PostListTree in special cases.
64 files changed:
xapian-core/api/database.cc
xapian-core/api/emptypostlist.cc
xapian-core/api/emptypostlist.h
xapian-core/api/enquire.cc
xapian-core/api/leafpostlist.cc
xapian-core/api/leafpostlist.h
xapian-core/api/postingiteratorinternal.h
xapian-core/api/postlist.cc
xapian-core/api/postlist.h
xapian-core/api/queryinternal.cc
xapian-core/backends/contiguousalldocspostlist.cc
xapian-core/backends/contiguousalldocspostlist.h
xapian-core/backends/glass/glass_alldocspostlist.cc
xapian-core/backends/glass/glass_alldocspostlist.h
xapian-core/backends/glass/glass_database.cc
xapian-core/backends/glass/glass_postlist.cc
xapian-core/backends/glass/glass_postlist.h
xapian-core/backends/inmemory/inmemory_database.cc
xapian-core/backends/inmemory/inmemory_database.h
xapian-core/backends/multi/multi_postlist.cc
xapian-core/backends/multi/multi_postlist.h
xapian-core/backends/remote/net_postlist.cc
xapian-core/backends/remote/net_postlist.h
xapian-core/backends/remote/remote-database.cc
xapian-core/backends/remote/remote-database.h
xapian-core/include/xapian/weight.h
xapian-core/matcher/andmaybepostlist.cc
xapian-core/matcher/andmaybepostlist.h
xapian-core/matcher/deciderpostlist.h
xapian-core/matcher/exactphrasepostlist.cc
xapian-core/matcher/exactphrasepostlist.h
xapian-core/matcher/externalpostlist.cc
xapian-core/matcher/externalpostlist.h
xapian-core/matcher/extraweightpostlist.cc
xapian-core/matcher/extraweightpostlist.h
xapian-core/matcher/localsubmatch.cc
xapian-core/matcher/localsubmatch.h
xapian-core/matcher/matcher.cc
xapian-core/matcher/matcher.h
xapian-core/matcher/maxpostlist.cc
xapian-core/matcher/maxpostlist.h
xapian-core/matcher/multiandpostlist.cc
xapian-core/matcher/multiandpostlist.h
xapian-core/matcher/multixorpostlist.cc
xapian-core/matcher/multixorpostlist.h
xapian-core/matcher/nearpostlist.cc
xapian-core/matcher/nearpostlist.h
xapian-core/matcher/orpostlist.cc
xapian-core/matcher/orpostlist.h
xapian-core/matcher/phrasepostlist.cc
xapian-core/matcher/phrasepostlist.h
xapian-core/matcher/postlisttree.h
xapian-core/matcher/queryoptimiser.h
xapian-core/matcher/selectpostlist.cc
xapian-core/matcher/selectpostlist.h
xapian-core/matcher/synonympostlist.cc
xapian-core/matcher/synonympostlist.h
xapian-core/matcher/valuerangepostlist.cc
xapian-core/matcher/valuerangepostlist.h
xapian-core/matcher/wrapperpostlist.cc
xapian-core/matcher/wrapperpostlist.h
xapian-core/net/remoteserver.cc
xapian-core/tests/api_percentages.cc
xapian-core/tests/api_weight.cc