diff options
author | Geir Storli <geirst@yahooinc.com> | 2024-05-06 13:47:30 +0000 |
---|---|---|
committer | Geir Storli <geirst@yahooinc.com> | 2024-05-06 13:47:30 +0000 |
commit | 30b6649d21ba30f4fb77e4c6530926c79414c5fd (patch) | |
tree | 41d34156abe2bd549056fa56eca7a60f2fb43e3f /searchcore/src | |
parent | 2f4511677d4da29e615f3543fd167d4bbce8588e (diff) |
Adjust down the estimate when its unknown and avoid WhiteListBlueprint being strict.
In cases where only attributes without fast-search are searched with e.g. an OR,
this change avoids sorting the WhiteListBlueprint first under the root AND, which is very costly to evaluate.
Diffstat (limited to 'searchcore/src')
-rw-r--r-- | searchcore/src/vespa/searchcore/proton/documentmetastore/lid_allocator.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/searchcore/src/vespa/searchcore/proton/documentmetastore/lid_allocator.cpp b/searchcore/src/vespa/searchcore/proton/documentmetastore/lid_allocator.cpp index 0c986422be6..758d1336399 100644 --- a/searchcore/src/vespa/searchcore/proton/documentmetastore/lid_allocator.cpp +++ b/searchcore/src/vespa/searchcore/proton/documentmetastore/lid_allocator.cpp @@ -210,7 +210,8 @@ private: } FlowStats calculate_flow_stats(uint32_t docid_limit) const override { double rel_est = abs_to_rel_est(_activeLids.size(), docid_limit); - return {rel_est, bitvector_cost(), bitvector_strict_cost(rel_est)}; + double do_not_make_me_strict = 1000.0; + return {rel_est, bitvector_cost(), do_not_make_me_strict * bitvector_strict_cost(rel_est)}; } SearchIterator::UP createLeafSearch(const TermFieldMatchDataArray &tfmda) const override |