Repository navigation
Conversation
A concurrent collector can already be parked for shared helpers when its mutator starts waiting for collection. Notify under the marking mutex and recheck the waiting bit before sleeping so the collector can drain its own work without relying on another heap to release helpers. Add a native regression that observes the actual collector and mutator parking addresses, holds shared helpers, and requires completion before helper release while preserving rooted objects. Include it in the existing native qualification gate.
This branch has not been deployed
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.
Main-branch companion of #21. The collector fix and native probe are identical; this branch uses its existing qualification script and inline receipt gate.
A worker can stall inside synchronous inspector GC while the main thread waits for its database work. A collector that has already entered passive draining checks
mutatorWaitingBitonly on entry. If its mutator starts waiting afterward and shared helpers are occupied by another heap, neither side wakes the collector to take over the marking work.Notify the marking condition under its mutex after releasing the thread lock, and recheck the waiting bit inside the passive loop. The collector then unlocks and drains actively. The 14 added production lines close both the missing notification and the missing predicate check; collection policy, helper counts, heap limits, and application concurrency remain unchanged.
The native regression uses actual Heap operations and ParkingLot observations, holds the shared helpers, and requires collection to finish before releasing them. The unchanged engine positively exhibits both parked waiters, with no timeout; the fixed engine completes and preserves rooted objects. The regression is included in the existing native qualification and its receipt verifier.
Validation so far:
Draft: paired Linux builds and the fixed 100/50 Gateway proof are still pending. No end-to-end load recovery is claimed yet. The separate heap-statistics cost is tracked in openclaw/openclaw#166104. Upstream searches found no matching repair; WebKit#72377 is already represented in the base and addresses a different notification path.