Do less useless intersections

This commit is contained in:
Clément Renault 2024-06-21 14:56:47 +02:00
parent 0ca1a4e805
commit 41f51adbec
No known key found for this signature in database
GPG key ID: F250A4C4E3AE5F5F
5 changed files with 31 additions and 23 deletions

View file

@ -251,6 +251,7 @@ pub fn compute_phrase_docids(
// We sort the bitmaps so that we perform the small intersections first, which is faster.
bitmaps.sort_unstable_by_key(|a| a.len());
// TODO use MultiOps intersection which and remove the above sort
for bitmap in bitmaps {
candidates &= bitmap;