WASM is already running in production at a whole bunch of financial services orgs and government infra.
The thing is, it's not running anywhere near HTML, CSS or JavaScript. It's running serverside, mostly on Wasmtime - which, as it happens, is what this post is all about.
The original Wasmtime 1.0 blog post explains it all really well: https://bytecodealliance.org/articles/wasmtime-1-0-fast-safe...
There’s plenty of usage in the browser environment as well, plenty of client-side SDKs for things like e.g. video editing, barcode scanning, etc. use it.
Native Client, which ran native x86 (but statically verified) code in the browser, basically fit all the criteria, except it wasn't platform agnostic. I'm not married to their approach, but I refuse to believe that this can't be done in a safe and peformant manner.
I guess WASM turned out to be a sandbagging rather than sandboxing technology.
But I eagearly await the arrival of concern trolls who can explain why WASM is slower than JS, and why native threading support is impossible to do securely without imposing limitations, that made sites like itch turn it off, so it might as well not exist.
Working on that! I'm building hypen.space which is platform agnostic language & SDK for building native crossplatform apps.
It's a WASM engine at it's core, and while currently it doesn't have "package this app as wasm" capability but supports streaming/local apps only, that capability is currently being developed - together with WASI layers for all of the platforms.
That way your app can run either as a browser (DOM) app, browser canvas app, native desktop or native mobile app.
It's still early, but moving fast - I just added accessibility support, and the animation framework will be out this week.
Regarding the WASM disappointed, when I started building this about 6 years ago, WASM was in a terrible (barely usable without wasting a ton of time) state. Now that WASI 0.3 is out and LLMs have sped up development by a large margin, it's in a quite usable state to ship things to production without fear.
Ironically, if it was today, Google could have pushed PNaCL without any problem.
So the upside of WASM according to you, is that it got greenlit by the standards committee chaired by companies whose business model would've been hurt the most by a competent in-browser sandbox.
For example, the Epic-Apple Fortnite battle couldn't even have happened. Epic would've shipped it on NaCL and users would've been just as happy, and Apple (or Google) would've had no way of enforcing their sandox.
Whew, thankfully we've been saved from that terrible fate of getting to publish and enjoy software without gatekeepers and appstores.
At least I hope you have something to gain from your opinion, as the rest of us certainly lost out.
On the client side, there's just a verifier, and then the runtime basically consists of branching to the first instruction and having at it. Near-native performance and instant startup, you can't do better than that.
PNaCL was proto-WebAssembly and suffering from the same issues. They actually shipped LLVM bytecode, and you had to compile the executable locally with the whole toolchain, leading to quite bad startup performance and a lot of baggage.
Turns out there's no such thing as portable VM assembly. You still have to ship a full compiler (well, JIT) and compile the WASM IR.
Browser vendors have spent uncountable amount of engineering resources on making yet another compiler (actually multiple, since afaik Chrome uses a tiered JIT for WASM), that's neither as good as the big boys, and neither as fast as just running the dang binary.
Only as a developer using the technology, as part of a failed commercial venture.
> If so, I'm curious to know why you think NaCL did not achieve broad adoption?
NaCl had 2 limitations compared to WASM, the first one was a design philosophy difference:
Unlike WASM, it was designed to maximize compatibility with native code, so it had no ability to coexist in the same process with JS/DOM like WASM does. You had to put the code in an iframe, and talk to it via postMessage. WASM promised to be a better design, but a decade on, we can see it's missing most of those promised features, or said features are half-baked, and it has turned into one of the biggest NIH quests in modern computer science.
The second issue was that it worked through Chrome's plugin API, which has since been deprecated. You could sit down and standardize an API that's not chrome specific. The biggest piece of API surface the browser has is WebGL, and they essentially exposed OpenGL ES to the browser, which is identical to what PPAPI did.
Some APIs were much better, like audio just gave you a buffer to write into, compared to WebAudio, which aims to implement the whole processing pipeline via stringing together JS objects, and everybody seems to hate it.
> And what's stopping the world from catching up to your line of thinking and adopting a NaCL successor?
Theoretically nothing, but you'd have to fork Chrome, do the changes yourself, develop a spec and tooling and THEN ask browser vendors to standardize on your changes. If there was some soul who would undertake this task (maybe feasible with AI for a non-huge team?), combined with a strong awareness campaign to get committees to consider adoption. So it's a tall order in reality.
Alternatively, the should've stuck with the NaCL approach of two separate, isolated worlds, with maximum compatibility and peformance for native code.