Parent: #467
At 80e4595, warmed ordinary, arrow, and generator-producing factories return the correct [6,6,6] result in Node, JavaScriptCore, and zig-js. Their optimizer artifacts are enabled but have zero native bytecode steps and exit before the first make_closure instruction.
Implement closure allocation through the canonical VM factory together with live activation storage. Closure publication makes a defining Frame escape; later reads and writes must observe the same synchronized bindings as captured functions, including changes made during callbacks. Recoveries must preserve canonical live storage rather than overwrite it with stale SSA snapshots.
Scope:
- Model closure allocation and activation storage locations as backend-neutral IR effects.
- Retain SSA locals for functions whose activation has not become observable; use canonical frame-backed bindings where closure allocation or lexical/mapped binding semantics require them.
- Preserve ordinary/named/arrow/generator/async template identity, lexical this/new.target/super/private/module context, immutable self-name bindings, capture environments, and existing allocation-failure behavior.
- Support exact regular, mapped, and lexical local access and initialization in the admitted storage model, including TDZ-before-immutable ordering.
- Preserve canonical frame locals across native callback, side exit and OSR; keep precise roots and escaped-frame synchronization.
Acceptance:
- Warmed factories execute actual native closure allocation and continue through correct live local reads/writes without stale snapshots or recompile loops.
- Off/on differentials cover escaped writes, closure callbacks mutating the defining activation, mapped parameters, lexical/TDZ/const behavior, named functions, arrows, generator/async templates, and realm/context capture.
- Serialized and no-GIL worker controls, GC/relocation, recursion, exact budget/termination, OOM and retirement tests pass.
- IR/native metadata verifiers reject malformed storage locations, local recoveries, operand roots, and activation requirements.
- Relevant Debug/ReleaseSafe/unsuppressed TSan, production, exact-parent conformance and threadfuzz gates pass with nonzero denominators. The combined cold unit link remains the separate human memory-policy blocker in #933.
- Document actual admission and the remaining #467 language/control boundary precisely.
No source-name recognition, copied environment snapshots, unsynchronized escaped-slot access, or disguised full-language claim.