Open Bug 1887040 Opened 2 years ago Updated 1 year ago

Support anyref parameters in JIT entry and exits

Categories

(Core :: JavaScript: WebAssembly, enhancement, P3)

enhancement

Tracking

()

People

(Reporter: rhunt, Unassigned)

References

(Blocks 2 open bugs)

Details

We only support externref in our JIT entry and exit stubs [1]. This means that any wasm func that uses anyref will need to fallback to the slower interpreter stubs. The original motivation for this was the anyref used to require type checks to ensure that the value passed fit in the type, and this added some complexity. However, the final spec has coercions so that any JS value can be present within anyref just like externref.

We should see if we can just remove this restriction. Because anyref and externref now act so similar, it might just be removing the guard.

[1] https://searchfox.org/mozilla-central/rev/a06d5a8871b1796f2dbd588ab518eaa98507e018/js/src/wasm/WasmTypeDef.h#73-111

Blocks: 1887041
Blocks: wasm-gc-perf
No longer blocks: wasm-gc
You need to log in before you can comment on or make changes to this bug.