6 ms·
I have used Go’s web assembly target a fair bit. The output wasm has an initial overhead of about a megabyte, and goes up pretty rapidly from there. This reall
by donatj 4y ago
I have used Go’s web assembly target a fair bit. The output wasm has an initial overhead of about a megabyte, and goes up pretty rapidly from there. This really limits the cases I’d like to use it in. Beyond that, the performance is generally several times slower than native.
I’ve had AssemblyScript recommended to me for exactly these reasons, but the one thing Go does have is a pretty great library ecosystem that AssemblyScript lacks.
- DanielHB 4y agoI had similar problems with C++ importing stdio printf gives almost no added binary size importing iostream cout << adds like 5mb to the final .wasm file from what I remember. I asked around and apparently it pulls a whole sort of random stuff into your binary like internationalisation and currency conversion (dots vs commas) Your native binaries do that as well, you just don't notice. Unless the compiler can offload some of these things to the OS-specific libraries