alt.hn

4/10/2026 at 7:03:39 PM

Watgo – A WebAssembly Toolkit for Go

https://eli.thegreenplace.net/2026/watgo-a-webassembly-toolkit-for-go/

by ibobev

4/11/2026 at 4:50:31 AM

I followed the same testing approach when writing a Wasm binary parser (technically, a decoder)[0].

It was pretty helpful having the official spec suite available and a major boost of confidence that your parser is compliant.

Nevertheless, it was my own tests that found a regression in the latest published version of the spec[1], which shows how important it is to have a variety of implementations.

[0] https://github.com/agis/wadec

[1] https://github.com/WebAssembly/spec/issues/2066

by pasxizeis

4/10/2026 at 8:33:54 PM

I need to check their harness, compare it to wazero's and my own (wasm2go)

Btw, if Eli reads this: thanks for the WAT samples, they were very helpful working on wasm2go!

by ncruces

4/10/2026 at 8:45:02 PM

You're welcome :)

The harnesses are documented here: https://github.com/eliben/watgo/tree/main/tests

Note that I had to switch the harness from wazero to Node (unfortunately!) when it turned out wazero doesn't support gc and other new proposals (e.g. your comment here https://github.com/wazero/wazero/issues/2483)

Thank you very much for maintaining wazero - I love that project, and am looking forward to being able to use it for this in the future.

by eliben

4/10/2026 at 10:56:28 PM

You're welcome :)

evacchi does most of the maintaining these days, but I'll keep helping as best as I can.

Your harness looks interesting to replace wast2json with watgo in wasm2go. Though my current problem is that I should be using the JSON to decide which tests to run (manual process so far), and to generate the more complicated test files (e.g. the ones that link modules together).

by ncruces

4/10/2026 at 9:03:38 PM

I'm working on EH right now! Slowly walking towards GC!!

by evacchi

4/11/2026 at 8:27:53 AM

This is a really interesting project. The ability to inspect and manipulate Wasm modules at runtime opens up a lot of possibilities for debugging and tooling. Curious whether you've benchmarked the overhead of the toolkit itself on larger Go-compiled Wasm binaries?

by wtbland

4/10/2026 at 9:28:49 PM

This looks really useful for pre-runtime inspection of WASM modules. Are you using it for any security or sandboxing use cases?

by igtumt