Hacker News new | ask | show | jobs
by adrianfcole 1492 days ago
nope this is all under the scenes. We formerly called this JIT, which was inaccurate but removed this confusion. Calling it AOT is more precise, but people ask this question. win some you lose some I guess!

Anyway, if you use `wazero.NewRuntime()` magically it redirects to `wazero.NewRuntimeCompiler()`[1]. When the compiler is in use, all the native stuff happens automatically and you don't need to change your binary based on the wasm you use.

This is actually neater than it seems as embedded compiler is goroutine safe, meaning you can compile modules concurrently.

https://pkg.go.dev/github.com/tetratelabs/wazero#NewRuntimeC...

1 comments

It sounds promising!

When explaining it, it might be a good idea to focus on a little more on what this technology can do for you: "How to add cross-platform plugin support to a Go program using WebAssembly."

thumbs up and subscribe to this :) https://github.com/tetratelabs/wazero/issues/577