Skip to content

Conversation

@KarthikSubbarao
Copy link
Member

@KarthikSubbarao KarthikSubbarao commented Nov 27, 2025

Please do not review yet - I am working on this PR when I get time in between some other core changes, and waiting for the core changes to first get merged into the fulltext branch. After that, I will have this branch updated on latest changes and mark it as ready for review.

In this PR, I optimize NextKey / NextPosition in TermIterator by using a priority queue for efficiently finding the min key and min position when using the key iterator and position iterator

@KarthikSubbarao KarthikSubbarao marked this pull request as draft November 27, 2025 08:14
@KarthikSubbarao KarthikSubbarao added the FT Pertains to the Full-Text project label Nov 27, 2025
key_iterators_(std::move(key_iterators)),
pos_iterators_(),
current_key_(),
current_position_(std::nullopt),
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: No need to initialize with std::nullopt, it's the default value.

Comment on lines +21 to +25
untracked_keys_(untracked_keys),
key_heap_(),
pos_heap_(),
current_key_indices_(),
current_pos_indices_() {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: no need to explicitly call the default constructor

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

FT Pertains to the Full-Text project

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants