WebAssembly Troubles part 4: Microwasm (2019)

https://news.ycombinator.com/rss Hits: 8
Summary

WebAssembly Troubles part 4: Microwasm Preamble This is the final part of a 4-part miniseries on issues with WebAssembly and proposals to fix them. Part 1 here, part 2 here, part 3 here. This article assumes some familiarity with virtual machines, compilers and WebAssembly, but I’ll try to link to relevant information where necessary so even if you’re not you can follow along. Also, this series is going to come off as if I dislike WebAssembly. I love WebAssembly! I wrote a whole article about how great it is! In fact, I love it so much that I want it to be the best that it can be, and this series is me working through my complaints with the design in the hope that some or all of these issues can be addressed soon, while the ink is still somewhat wet on the specification. Wasm is mostly a great spec, but it has some serious problems. I’ve detailed some of these issues in the previous three articles in this series, but it might seem like actually fixing these problems is untenable. Are you really going to deprecate locals? You’re going to deprecate if? Well, turns out we don’t need to - we can get many of the desired benefits without dropping support for WebAssembly as it exists now. Introducing Microwasm Microwasm (working title) is Wasm-compatible format that can be efficiently consumed by runtimes and efficiently produced by compilers like LLVM. It’s currently implemented in the Microwasm branch of Lightbeam. The main goals are as follows: It should be relatively easy to implement each of the following three steps: Compiler IR->Microwasm; Wasm->Microwasm; Microwasm->Native. It shouldn’t sacrifice any of WebAssembly’s guarantees on safety or determinism. We should maximise the amount of useful information transferred from the compiler producing the Microwasm to the runtime consuming the Microwasm. We should optimise for performance when consuming a stream of Microwasm, unless it conflicts with the performance goals of optimising compilers. Converting Wasm to Microwa...

First seen: 2025-07-02 19:57

Last seen: 2025-07-03 02:59