fix(gc): preserve young logs across promotion rollback - #9924
fix(gc): preserve young logs across promotion rollback#9924proggeramlug wants to merge 2 commits into
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Team Run ID: 📒 Files selected for processing (3)
Included review availability: Your plan provides up to 8 included reviews per hour; 7 remain after this review. 📝 WalkthroughWalkthroughThe GC now retains young side-table roots when speculative in-place promotion rolls back. A new integration test verifies retry evacuation of a value reachable only through a young log. ChangesPromotion rollback handling
Estimated code review effort: 3 (Moderate) | ~20 minutes Merge Risk: ⚪ Minimal · up to This preserves closure side-table roots across failed speculative promotion and verifies that evacuation retry retains the live young value. No merge-blocking risk remains. 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
Landed on |
The first copying minor can speculatively retag nursery blocks as
PromotedYoung, trace them, then roll back when measured survival is low. Young-entry side-table scanners treated that temporary space as ordinary old generation and drained their remembered keys during the speculative trace. The evacuation retry then skipped roots reachable only through those tables, causing nondeterministic corruption such asSet.prototype.add is not a functionduring Claude-of-Duty world construction.Keep
PromotedYoungaddresses minor-relevant until the promotion commits, using the existing cached heap-space classifier. This preserves the logs across rollback while allowing the next ordinary minor to discard entries after a successful promotion. The regression test forces a traced first-cycle rollback with a young value reachable only through a closure side table; it fails before the fix because the retry leaves the stale from-space address.Validation:
cargo test -p perry-runtime --profile perry-dev -- --test-threads=1(3,243 passed, 4 ignored; 8 doc tests ignored)cargo test -p perry-stdlib --profile perry-dev -- --test-threads=1(132 passed)./scripts/run_lint_gates.sh(all 64 gates passed; 2 CI-only expressions skipped locally)Fixes #9907
Summary by CodeRabbit
Bug Fixes
Tests