fix(codegen): retain typed arrays across specialized calls - #9812
fix(codegen): retain typed arrays across specialized calls#9812proggeramlug wants to merge 1 commit 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 (6)
Included review availability: Your plan provides up to 8 included reviews per hour; 5 remain after this review. 📝 WalkthroughWalkthroughSpecialized typed-array calls now keep boxed owners alive through the call. Native root coverage parses quoted specialized callees and verifies statepoint liveness. A GC-stress regression test covers module-level and local typed arrays. ChangesTyped-array lifetime retention
Estimated code review effort: 3 (Moderate) | ~20 minutes Merge Risk: ⚪ Minimal · up to Specialized typed-array calls now retain their boxed owners until return, preventing storage reclamation during full GC while preserving the raw-pointer calling convention. The implementation is covered by native-root and GC-stress regressions, with no remaining concrete merge-blocking risk. 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
Full details: Docstring CoverageExplanation Docstring coverage is 55.56% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 9 functions across 5 files. (1 skipped: 1 unsupported.)
✨ 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 |
A specialized typed-array call passes a raw header pointer and relies on the caller to retain the array. At a binding's last use, native GC liveness could end while preparing that raw argument. A full collection inside the callee then reclaimed its array storage;
taMixin the representation stress fixture returned a corrupted checksum.Keep the boxed typed-array owner live until the specialized call returns, including the guarded fast-call path. This preserves the raw calling convention and hoisted element access. The regression covers both module and function-local last uses. The native-root harness also recognizes LLVM's quoted specialized function names so it can verify these calls directly.
Closes #9782.
Validation:
perry-devcompiler/runtime/stdlib build, Node-version consistency, Rust file-size, and diff checks pass.No collector policy change or version bump.
Summary by CodeRabbit
Bug Fixes
Tests