Hacker News new | past | comments | ask | show | jobs | submit login

You can polyfill SIMD, but you can't polyfill threads. Once you add shared memory between workers, you've effectively violated the premise that asm.js will run everywhere, even places that don't understand it.

In that case, you've got a portable intermediate representation of opcodes in a bloated legacy format, that is now incompatible with legacy runtimes. Why use JS format then?




Apps could feature detect threading and fall back to single-threaded mode for compatibility with non-asm browsers if it's not supported.

Regarding the claim that asm.js is "bloated": http://mozakai.blogspot.com/2011/11/code-size-when-compiling...


SIMD is coming to JS, it's as short a path as adding to Dart (and Dart is not going cross-browser, so...).

Why JS format? Because another syntax that's both fast to lex+parse and not future-hostile (as JVML was) is a tall order and we'll get to it only when we really need it. Adding SIMD to JS does not require adding a whole new syntax!

/be




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: