logoalt Hacker News

dfabulichtoday at 6:56 AM2 repliesview on HN

Basically never, because it would require re-standardizing the DOM with a lower-level API. That would take years, and no major browser implementor is interested in starting down that road. https://danfabulich.medium.com/webassembly-wont-get-direct-d...

Killing JavaScript was never the point of WASM. WASM is for CPU-intensive pure functions, like video decoding.

Some people wrongly thought that WASM was trying to kill JS, but nobody working on standardizing WASM in browsers believed in that goal.


Replies

pjmlptoday at 8:43 AM

People have to look at it, from the same point of view Google sees the NDK on Android.

"However, the NDK can be useful for cases in which you need to do one or more of the following:

- Squeeze extra performance out of a device to achieve low latency or run computationally intensive applications, such as games or physics simulations.

- Reuse your own or other developers' C or C++ libraries."

And I would argue WebGL/WebGPU are preferably better suited, given how clunky WebAssembly tooling still is for most languages.

malletstoday at 9:05 AM

A bit unrelated, but are there any recent benchmarks comparing it with native perf?

Hard to believe it can compete with V8 JIT anytime soon. Might be easier to integrate fast vector libraries within javascript engines.