2 ms·
Depends if you measure against asm.js or handwritten Javascript, and on which browser. For my emulator stuff (mostly bit twiddling on integers: https://floooh.
by flohofwoe 8y ago
Depends if you measure against asm.js or handwritten Javascript, and on which browser.
For my emulator stuff (mostly bit twiddling on integers: https://floooh.github.io/tiny8bit/ https://floooh.github.io/tiny8bit/), I saw a very slight improvement of WASM vs asm.js on browsers that have special handling for asm.js (in the meantime I have dropped asm.js, and only compile to WASM, since all browsers support it).
On iOS Safari (which I guess doesn't have special asm.js handling) WASM is a whopping 3x..5x faster than running the same code compiled to asm.js.
The question now is how much slower 'idiomatic, handwritten Javascript' is on iOS Safari versus the same code written in C compiled to asm.js, but I think another 3x..5x slower is realistic.