Parent: #144 Roadmap: #134 Related: #325
Define the auditable pointer and identity contract required before any heap cell can move. This is a correctness foundation, not a claim that compaction is active.
Scope
- Inventory every heap-cell pointer representation and owner: NaN-boxed Values, raw typed pointers, atomic slots, native-private data, Wasm references, weak/finalization records, C/Objective-C/private-ABI handles, debugger state, interpreter frames, and JIT metadata.
- Classify each occurrence as immovable, stable-handle-backed, precisely rewritable, interior, or forbidden across a safepoint.
- Define a relocation visitor API distinct from marking, including strong, weak, ephemeron, atomic, optional, and interior-reference operations.
- Define stable object identity across relocation and the forwarding metadata/header lifecycle.
- Add a checked-in machine-readable inventory plus a verifier that fails on drift in declared pointer-bearing fields and root registries.
- Document safepoint and native embedding rules without enabling movement yet.
Acceptance
- Every production GC cell kind and root registry appears in the inventory with an explicit rewrite strategy.
- The relocation visitor can express all current tracing edges without silently treating raw pointers as stable.
- Forwarding metadata and stable identity rules are represented in code and covered by focused tests.
- C API, Objective-C, Bun/Home ABI, inspector, Worker/Thread, Promise/module, Wasm, and JIT boundaries have explicit dispositions.
- Inventory/verifier, focused normal tests, and focused TSan tests pass with zero leaks.
- #144 is updated with the committed evidence and the next child is unblocked.