Skip to content

Conversation

@stuhood
Copy link
Collaborator

@stuhood stuhood commented Nov 3, 2025

The new API proposed in #2726 enables implementing Collector::collect_block, which allows for slightly more efficient bulk pushes to the TopNComputer when a SegmentSortKeyComputer::is_lazy, and when scores are not required.

We can:

  • Check capacity and truncate once for the entire block.
  • Lift the check for the presence of a threshold out of the loop over the block.

It would additionally allow for bulk fetching (using ColumnValues::first_vals) the first sort key column, as future work.

I haven't benchmarked this yet! But collect_block is quite beneficial for aggregations.

@stuhood stuhood mentioned this pull request Nov 3, 2025
@stuhood stuhood force-pushed the stuhood.lazy-scorers-blocks branch from 704a0c5 to e73c945 Compare November 3, 2025 06:01
@fulmicoton-dd fulmicoton-dd force-pushed the paul.masurel/lazy-scorers branch 9 times, most recently from a55995a to 71d9a5d Compare November 10, 2025 13:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant