You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* test: normalize method literal GC arms
* docs(runtime): pin captured cache hint bounds
* runtime: allocate native async-resolution promises in malloc space
Native async resolutions (fetch/db/ws/etc.) created their Promise via the
nursery arena (js_promise_new), pinned it, and handed the raw pointer to a
tokio worker. A copying-minor from-space flip wipes a nursery resident
regardless of its pin flag (the flip resets eden/survivor blocks wholesale;
only root-reachable pins force the fallback), so the worker's later resolution
dereferenced a reclaimed Promise -> SIGSEGV in js_stdlib_process_pending.
Allocate these promises via js_promise_new_cross_thread (malloc space,
non-moving; both sweep paths honor GC_FLAG_PINNED). Re-export the symbol from
perry-runtime and switch every native-binding caller.
Found getting the compiled Claude Code CLI to run natively; confirmed to remove
the js_stdlib_process_pending fault under PERRY_GC_PROTECT_FROMSPACE.
Claude-Session: https://claude.ai/code/session_01TwxRkALrR9HKSF1zKLSTAF
* runtime: root async-from-sync iterator objects across GC safepoints
The %AsyncFromSyncIteratorPrototype% helpers created nursery objects (the
wrapper, the outer promise, reaction closures, the iter result, the captured
sync iterator) and held them as raw pointers across later allocations and JS
calls. Under the default-on moving young-gen scavenge those raw pointers are
invalidated (evacuated, or swept when unreachable), so a later use dereferenced
a stale/poison receiver.
Root every live young value in a RuntimeHandleScope and re-read it through the
handle after each allocation/JS call; use the long-lived string allocator for
the immortal property-name keys. Covers wrap_iterator, install_next/method,
next/return/throw, call/call_raw, continue, fulfilled/rejected_value, and
iter_result.
Claude-Session: https://claude.ai/code/session_01TwxRkALrR9HKSF1zKLSTAF
* chore: fmt + raw-handle ceiling for array/iterator.rs (#8801)
---------
Co-authored-by: Ralph Küpper <ralph@skelpo.com>
0 commit comments