Recently I read asm.js
spec and it seems cool but is there any environment/tool to develop and test this tool or not? Is that still on spec phase only?
Asked
Active
Viewed 3,109 times
7

Afshin Mehrabani
- 33,262
- 29
- 136
- 201
2 Answers
6
You can try it by using emscripten with ASM_JS=1 and running it in a firefox build from a side branch. Links and more instructions are in these slides about asm.js, http://kripken.github.com/mloc_emscripten_talk/#/

Alon Zakai
- 1,038
- 5
- 4
-
1Note asm.js compilation is [now available in Nightly](https://blog.mozilla.org/luke/2013/03/21/asm-js-in-firefox-nightly/) – robertc Mar 26 '13 at 14:29
-
1The talk is not terribly informative regarding setup/config. Download the llvm source, download clang and put it where it asks to be in the llvm source, make and make install. Clone the emscripten repo to use the command emcc to compile c/c++ to js. – meawoppl Aug 12 '13 at 14:10
2
Use the '-s' command line option of the compiler, like thus:
./emcc -O1 -s ASM_JS=1 tests/hello_world.c

Bram
- 7,440
- 3
- 52
- 94