4 ms·
What is `wasm_gc` all about?
by Karrot_Kream 8y ago
What is `wasm_gc` all about?
- tyingq 8y agoThe reason the switch is called that... "A new proposal has been made to the WebAssembly specification committee a few months ago: to add reference types to the type system. Reference types are a new way to represent a reference to any host values. In a Web environment, this means being capable of playing with JavaScript values within WebAssembly. This is a huge difference with the existing type system, which only contains primitive types: integers represented on 32 or 64 bits, IEEE754 floating-point numbers represented on 32 or 64 bits. This is also a first step for implementing garbage collection (GC) integration within WebAssembly: since these reference values have been allocated on the GC heap in JavaScript, they need to be traced during wasm execution." https://blog.benj.me/2018/07/04/mozilla-2018-faster-calls-and-anyref/ https://blog.benj.me/2018/07/04/mozilla-2018-faster-calls-an...