A Compiler Author’s Guide to WebAssembly GC by Oscar Spencer @ Wasm I/O 2025
Wasm I/O 2025 - Barcelona, 27-28 March Slides: https://docs.google.com/presentation/d/17WOgQjSGMmH92yRGfO4rkxL3Ir3xPlM-T1r0Ff1DDCk/edit?usp=sharing The WebAssembly GC proposal is a game changer for high-level programming languages, offering the potential to streamline memory management, reduce module sizes, and improve execution speed. This proposal significantly reduces the need for languages to inject complex runtime code to manage memory, making WebAssembly applications built from these languages far more competitive with lower-level languages. In this talk, I’ll share my experience transitioning the compiler for the Grain programming language from its current linear memory model to the new Wasm GC proposal. I’ll dive into the technical challenges, the lessons learned, and the changes made to the compiler to leverage WebAssembly’s new garbage collection features. Through this case study, I’ll explore how this proposal will impact the development of compilers for high-level languages and what it means for optimizing performance in Wasm-based applications. Beyond compiler-specific details, I will also discuss the broader implications of Wasm GC for the WebAssembly ecosystem, particularly in relation to the WebAssembly Component Model. What does it mean for modularity, interoperability, and the future of WebAssembly as a platform for polyglot languages and applications? Attendees will leave with a deeper understanding of WebAssembly’s evolving capabilities, how Wasm GC affects both high-level language implementation and the broader ecosystem, and how it will shape the future of WebAssembly.