ReviewOS

zig-utils/zig-js

WebAssembly bulk memory: execute table operations and passive reference segments

#278
Closed chris opened this 9 days ago ·
9 days ago

Parent: #272 Depends on: #276, #274 Roadmap: #263, #142, #134

Implement table bulk operations, passive element lifecycle, and exact host-visible reference synchronization.

Acceptance:

  • Instantiate active/declarative element segments correctly and retain/drop passive elements per instance.
  • Execute table.init, elem.drop, and table.copy with exact overlap, type, bounds, and trap ordering.
  • Preserve funcref/externref identity across multiple and cross-instance tables.
  • Publish passive/table reference edges to precise GC and synchronize Wasm mutations with JavaScript Table wrappers and barriers.
  • Add focused executor, cross-instance, precise-GC, and JavaScript API coverage.
9 days ago

Completed in d5eef86a, 4c61bd90, and 66237d21. Passive/declarative element state and table.init/elem.drop/table.copy are exact; observed table writes/grows synchronize JavaScript mirrors under consistent host/table locking; externref barriers retain and reclaim exactly; lazily materialized funcrefs remain canonical. The API proof includes a function owned by one Wasm instance copied through tables operated by another. Combined evidence is 159/159 at 4c61bd90, plus the strengthened 3/3 witness at 66237d21, with zero skips/failures/leaks.

Sign in to comment on this issue.