Repository navigation
[MOD-17684] Give OptimizedWildcard a suspended counterpart - #10896
Merged
Merged
Conversation
1 of 4 tasks
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #10896 +/- ##
==========================================
- Coverage 83.16% 82.22% -0.94%
==========================================
Files 606 635 +29
Lines 80987 82402 +1415
Branches 36248 37614 +1366
==========================================
+ Hits 67350 67757 +407
- Misses 13290 14301 +1011
+ Partials 347 344 -3
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Add `OptimizedWildcardSuspended`, its layout-invariant proof, and the `RQEIteratorBoxed` impl that pairs them. Extracted from the UnionOpaque revision, which carried this wildcard machinery for no reason of its own.
LukeMathWalker
force-pushed
the
luca-reval-wildcard-machinery
branch
from
August 17, 2026 10:49
76f84a4 to
2af2ebb
Compare
|
gdesmott
approved these changes
Aug 17, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



Describe the changes in the pull request
OptimizedWildcard— the wildcard iterator reading the existing-docs inverted index — has no suspended counterpart, so neither it nor the enums that wrap it can be held across a release of the index spec read lock.RQEIteratorBoxed::suspend/RQESuspendedIterator::resume. The enum is re-shaped into aRef-mode-parametrizedRawOptimizedWildcard, so suspending is a layout-preserving reinterpretation of the same allocation rather than a rebuild, with each arm's inverted-index wildcard transitioned in place. Same shape as [MOD-17682] NumericIteratorVariant: suspend/resume #10894'sRawNumericIteratorVariant; the legacyrevalidateis unchanged.DiskWildcardIterator,NewWildcardIterator) and any composite over wildcard children.Which additional issues this PR fixes
Main objects this PR modified
RawOptimizedWildcard<'query, Rf>plus theOptimizedWildcard/OptimizedWildcardSuspendedaliases — one generic enum rather than a hand-maintained pair, so variant order and tag encoding agree by construction. Theconstproof asserts what is left: arm correspondence (anIsSamewitness that suspending an arm yields exactly the matching arm) and per-arm plus whole-enum layout identity.suspend/resumeon the enum — reuse the heap allocation so external borrows into the iterator's interior stay valid, and drive each arm through the shared child-slot helpers.existingDocs,Movedwhen the current document was collected,Okotherwise. Stating it in the wrapper as well is what would let the two drift apart.inverted_indexvisibility —core, andRawWildcard'sitfield andshould_abort, go back to private now that the wrapper reaches the arm through its trait impl instead of past it.tests/integration/wildcard.rs— round trip per variant (box-address stability, and that the cast lands on the same variant), plus the nulled, replaced, and current-document-collected cases against a real existing-docs index.Mark if applicable
Release Notes