Re:WebAssembly without the browser
by nicetryguy on Sunday August 16, 2020 @09:27PM
(#24182933)
If you are going to target WebAssembly outside of a browser environment, uh, why not just target LLVM, GNU, or uh, you know, Assembly... X86_64 or ARM are pretty standardized. Another part 1/1 "tutorial" with some brilliant insight as per usual.
[ Parent
| on HN ]
There seems to be a section in the article called "Why would we want to run WebAssembly outside of a browser?" that I think addresses what you're asking?
LLVM bitcode is, I believe, not portable. Neither is Assembly. Nor are the resulting binaries of that processed something that is run within a sandbox.
This, i think webassembly is the sweet spot. It has portability but doesn't have any opinion about how the code should be structured. No opinion about GC or objects etc.
Works really really great with Rust.
Yes. Because WebAssembly provides a higher level of abstraction (safety, isolation, portability, manageability etc — you know, the “enterprise” stuff) over native code. See here: https://www.secondstate.io/articles/why-webassembly-server/
Because WebAssembly allows you to sandbox the code, which you can't with regular assembly.
Re:WebAssembly without the browser
by otabdeveloper4 on Monday August 17, 2020 @08:47AM
(#24186702)
Sure you can. The so-called "virtual machines" have existed for a while now. :)