asm.js in Firefox 22 is CRAZY fast!

Firefox discovered that if you restrict allowable JavaScript to just a subset of the total language, it can be run at almost native speeds! Running this demo ( lljs cloth demo ) in the new Firefox 22 ran at 3 times the speed of Chrome! (This fits with the previous tests I’d seen in articles).

Update to Firefox 22 and give it a try in both that and Chrome.

lljs cloth demo

I get “Cloth dimensions: 141, 66” on Fx 20 (equivalent)

Even though it states on that site.

This demo is out-of-date and no longer validates as asm.js code. It will be fixed soon, so please come back for a much refreshed demo.

Testing with Firefox 21.0 I get, Cloth dimensions: 130, 61 (Mozilla/5.0 (X11; Linux x86_64; rv:21.0) Gecko/20100101 Firefox/21.0)

Testing with Firefox 22.0 I get, Cloth dimensions: 172, 82 (Mozilla/5.0 (X11; Linux x86_64; rv:22.0) Gecko/20100101 Firefox/22.0)

Testing with Nightly I get, Cloth dimensions: 128, 60. (Mozilla/5.0 (X11; Linux x86_64; rv:25.0) Gecko/20130626 Firefox/25.0)

Testing with Chromium I get, Cloth dimensions: 90, 41 (Version 27.0.1425.0 (185065)

So if higher numbers are better, there appears to be a slight degradation in Nightly. Hope it is fixed by September.

So what the hell does all this mean??? Can someone please give some non-cloth-dimensions explanation? BTW, how am I getting away with all this profanity tonite, usually it is blocked immediately.

Faster JavaScript

Surprise! Mozilla can produce near-native performance on the Web | Ars Technica

Martin Best Blog » Blog Archive » asm.js: it’s really fast, backwards compatible, and now in the release version of Firefox.