Now, how long until Chrome supports it...
Now, how long until Chrome supports it...
And who cares what OS you're running - if you can compile your application to asm.js, which runs at only half the speed of C[1], then you can make it available to everyone.
[1] See: the image here: http://www.extremetech.com/computing/151403-firefox-sticks-i...
Sadly this is one area where plugins still rule and advance innovation. That has made it into the web quite a bit in html5 but still a bit to go before it is stable for 3D without a plugin. Three.js, fallbacks to canvas, etc are awesome and work today (hardware limitations on mobile, browser limitations like IE no webgl). But for intense 3d games some hardware acceleration is needed that is consistent. I am working on a bunch of canvas mobile apps right now and the speeds are problematic with many sprites, would love more hardware access.
If Mozilla can truly get 3d mobile browser gaming going with this (which currently there is no solution other than hardware accelerated canvas) then that opens up interesting areas. Also opens up new security issues. In terms of business/product use that isn't highlighting new tech, it is still a bit away.
The problem it has is that it is largely opaque to the JITs in browser engines (even PNaCl, since JS JITs have nothing to do with llvm). One way to fix that would be to define a simple byte code as a compilation target and have people compile to that, in addition to compilation to JS with emacripten. The end result would be, in my opinion, much cleaner than the ugly hacks in asm.js
Furthermore, by design, asm.js will always need guards in the generated code, thus some overhead that can never be fully removed (although JITs will help with this). In particular, one can write "x = +x" in JS, but then change the type of x, thus invalidating the invariant. A guard will be needed to guarantee correctness, since asm.js is a subset of JS, but the outer set still exists.
It seems to me that web technologies are getting more and more crazy. To me it appeared obvious that asm.js is not a nice approach, but I can see many people disagree.
/be