Skip to content

nit: Hoist bf_query_dataset construction out of candidate-doc loop#1498

Open
lyang24 wants to merge 1 commit intozilliztech:mainfrom
lyang24:hoist-bf-query-dataset
Open

nit: Hoist bf_query_dataset construction out of candidate-doc loop#1498
lyang24 wants to merge 1 commit intozilliztech:mainfrom
lyang24:hoist-bf-query-dataset

Conversation

@lyang24
Copy link
Contributor

@lyang24 lyang24 commented Mar 13, 2026

Move query-tensor pointer calculation and GenDataSet() call from the inner per-candidate loop to the outer per-query-emb-list loop in stage 2. These values are invariant across candidate docs, so building them once per query emb-list avoids repeated small-object allocation overhead.

…chEmbList

Move query-tensor pointer calculation and GenDataSet() call from the
inner per-candidate loop to the outer per-query-emb-list loop in stage 2.
These values are invariant across candidate docs, so building them once
per query emb-list avoids repeated small-object allocation overhead.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: lyang24 <lanqingy93@gmail.com>
@sre-ci-robot
Copy link
Collaborator

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: lyang24
To complete the pull request process, please assign marcelo-cjl after the PR has been reviewed.
You can assign the PR to them by writing /assign @marcelo-cjl in a comment when ready.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@mergify
Copy link

mergify bot commented Mar 13, 2026

@lyang24 🔍 Important: PR Classification Needed!

For efficient project management and a seamless review process, it's essential to classify your PR correctly. Here's how:

  1. If you're fixing a bug, label it as kind/bug.
  2. For small tweaks (less than 20 lines without altering any functionality), please use kind/improvement.
  3. Significant changes that don't modify existing functionalities should be tagged as kind/enhancement.
  4. Adjusting APIs or changing functionality? Go with kind/feature.

For any PR outside the kind/improvement category, ensure you link to the associated issue using the format: “issue: #”.

Thanks for your efforts and contribution to the community!.

@alexanderguzhva
Copy link
Collaborator

@foxspy were there any problems with our CI recently?

@alexanderguzhva
Copy link
Collaborator

/kind improvement

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants