Hacker News new | ask | show | jobs
by GotNothing 4834 days ago
As soon as they find a way to put ads in it...
3 comments

yes, because chrome is so full of ads...
on the loading screens!
Chrome has supported NaCl for a long time, which is quite a bit saner than asm.js
You show up on every NaCl-related thread claiming it is awesome and asm.js is crap, but that's as far as it goes - you never explain why. You're basically wasting time because what you say is never actionable. Please defend your opinions - inform us!
(P)NaCl exposes pretty much the same environment and tool chain devs get writing native apps. Predictable performance, decent debugging, etc. One can even decide to use platform-specific features if strictly necessary.

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.

You are mistaken, there are no type guards within asm.js-verified/compiled/linked code. Read more at http://asmjs.org/.

/be

You're too early for April Fools, but you almost got me.