Skip to content

Deyu/perf - #1280

Merged
cave-g-f merged 2 commits into
jegao/LabelHotFixfrom
deyu/perf
Jul 28, 2026
Merged

Deyu/perf#1280
cave-g-f merged 2 commits into
jegao/LabelHotFixfrom
deyu/perf

Conversation

@cave-g-f

Copy link
Copy Markdown
  • Does this PR have a descriptive title that could go in our release notes?
  • Does this PR add any new dependencies?
  • Does this PR modify any existing APIs?
  • Is the change to the API backwards compatible?
  • Should this result in any changes to our documentation, either updating existing docs or adding new ones?

Reference Issues/PRs

What does this implement/fix? Briefly explain your changes.

Any other comments?

Deyu Kong added 2 commits July 28, 2026 16:30
test_full_mask_val's AVX2 fast path issues an unconditional 256-bit
(4-word) load over the query mask, so every query bitmask buffer must be
at least AVX2_TAIL_PADDING words long and fully zeroed -- otherwise stale
high words (from a reused scratch buffer) or out-of-bounds reads (from a
buffer sized to bitmask_size < 4) participate in the AND and produce
false label matches. This corrupted both filtered search recall and
filtered graph construction.

- bitmask_filter_match::build_query_mask: single place that sizes and
  clears the query mask (clear + resize to >= AVX2_TAIL_PADDING), shared
  by both ctors.
- aggregate_points_by_bitmask_label: pad + zero the per-label query mask
  (was sized to bitmask_size, under 4 words).
- Add AVX2 correctness corner-case tests: single-word no-cross-point
  leak, reused-buffer re-zeroing, word-boundary labels, universal label,
  and large-size AVX2-block-plus-scalar-tail.
@cave-g-f
cave-g-f merged commit f9e3318 into jegao/LabelHotFix Jul 28, 2026
3 of 39 checks passed
@cave-g-f
cave-g-f deleted the deyu/perf branch July 28, 2026 11:59
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