Hoist UringState.enqueue's SQE fill onto an inout ring parameter - #11
Merged
Conversation
Spelling the uring.next.entry chain on the class's stored property trips a SILGen assertion on the pinned Swift 6.4 release-floor toolchain (SILGenLValue.cpp:3203, SILGenBorrowedBaseVisitor::getLookupExprBaseLValue, !e->getType()->is<LValueType>()): the borrowed-base visitor cannot lower a mutating _read (next) chained through a ~Copyable ~Escapable slot when the base is a class ivar lvalue. This reddened every consumer's Linux release leg once swift-institute/.github#487/#495 pinned the assertions-enabled 6.4 image. Delegate the instance method to a private static enqueue(into:_:target:) taking the ring inout. Call-site spelling, guards, and semantics are unchanged (the #105 hoist pattern). Verified: swift build -c release in the exact pinned CI image crashed before and completes after this change. Tracking: swift-institute/Issues#108. Remove the hoist when the pinned toolchain no longer asserts on the class-ivar spelling.
Contributor
There was a problem hiding this comment.
Approving the #105-pattern hoist: minimal, semantics-preserving, evidence on the run (31381920572) and swift-institute/Issues#108.
This was referenced Aug 10, 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.
Consumer-lawful workaround for swift-institute/Issues#108 (Swift 6.4 release-floor SILGen assertion in
Kernel_Completion.UringState.enqueue), unblocking swift-foundations/swift-linter#46's Linux release legs.Defect: on the pinned release-floor image (
swiftlang/swift@sha256:8d6141…, 6.4-dev +assertions), spelling theuring.next.entrychain on the class's stored property aborts silgen:SILGenLValue.cpp:3203,SILGenBorrowedBaseVisitor::getLookupExprBaseLValue, assertion!e->getType()->is<LValueType>()— amutating _read(next) yielding a~Copyable ~Escapableslot, chained throughentry, on a class-ivar lvalue base. Exposure was toolchain drift (swift-institute/.github#487/#495 image pin), not source drift; reduction on the issue.Change: delegate the instance method to a
private static func enqueue(into uring: inout Kernel.IO.Uring, _:target:)— the #105 hoist pattern. Call-site spelling, guards, and semantics unchanged; +21 lines, no API change.Evidence (local, exact pinned CI image):
swift build -c releaseon main crashes with the identical assertion/symbol; with this change it completes, andswift test -c releasepasses 360 tests in 209 suites.Removal condition: when the pinned floor toolchain no longer asserts on the class-ivar spelling (re-verify by reverting the hoist against the then-current image). No upstream filing per standing policy.
Forensic-repair lane, coordinator session 8830f961.