PDA

View Full Version : Firefox 3.1 JS Performance: TraceMonkey



nlotz
23 Aug 2008, 9:44 AM
I want to suggest an article on TraceMonkey (the JIT-compiler that will boost JS-performance in Firefox 3.1):

Andreas Gal: Tracing the Web (http://andreasgal.com/2008/08/22/tracing-the-web/)

For the SunSpider ubench suite, which focuses on core JavaScript language features, we achieve a speedup of 22x (compared to Firefox 3.0). Whichever metric you chose to apply, Firefox now has the fastest JavaScript engine in the world.

If you want to check out TraceMonkey yourself (and have worked with nightly builds before):

1.) Grab, install and run a nightly build (http://ftp.mozilla.org/pub/mozilla.org/firefox/nightly/latest-trunk/) of Firefox 3
2.) Go to about:config and set the property javascript.options.jit.content to true
3.) Check out your favourite site packed with JS and start drooling

Animal
23 Aug 2008, 9:54 AM
The nighly build won't override my stable 3.0 installation will it?

nlotz
23 Aug 2008, 11:05 AM
The nighly build won't override my stable 3.0 installation will it?
No - it will install as an application called Minefield - but beware: it will share all settings and add-ons with your stable 3.0 installation. So when you uninstall Minefield, then don't remove the settings or they will be lost forever. Also it may try to update your add-ons and other components. You can avoid most of that by using multiple profiles. There is a nice tutorial on multiple Firefoxes on the same machine, but I can't find it at the moment.

ktilt
23 Aug 2008, 12:44 PM
i tried last nights build but experienced a lot issues on my apps (both which work flawlessly on FF 3.0.1). one wouldnt load at all getting a 'x.el does not exist' error in ext-all.js while the other loaded fine but a few of the more advanced features failed to work. that app did seem snappier for the stuff that did work though which was nice.

im curious what other's are experiencing with 3.1 and extjs.

ENEMYoftheSUN
23 Aug 2008, 1:26 PM
i tried last nights build but experienced a lot issues on my apps (both which work flawlessly on FF 3.0.1). one wouldnt load at all getting a 'x.el does not exist' error in ext-all.js while the other loaded fine but a few of the more advanced features failed to work. that app did seem snappier for the stuff that did work though which was nice.

im curious what other's are experiencing with 3.1 and extjs.

Hello
I use the latest nightly too, and I can confirm it to you, there's an error : "this.el does not exist". This error seems to be triggered by ext.form.field class :-/.

http://pix.nofrag.com/2/6/4/736fa91c897339994de66c1dfe78c.htmlhttp://pix.nofrag.com/2/6/4/736fa91c897339994de66c1dfe78c.png
(FF3.1a2pre / Firebug 1.2.0 / extJS 2.2 / JIT off)



About JIT, it really speeds up extJS applications... but with some bugs, as you can see in the following screenshot showing a "simple" ext.TabPanel with 4 items (ext.Panel) in it, with JIT turned ON :
http://pix.nofrag.com/7/6/5/9e0ad31271ae900d8f3debdc74e79.jpg

BTW, I think the bugs come from the JIT side, not extJS. But it's promising, I have some big grids that take almost 3 seconds to be rendered, and once JIT is on, it's nearly instantaneous !



>Animal
If you want to try Minefield, it's easy : first of all, create a new firefox profile (just run "c:\program files\mozilla firefox\firefox.exe -p", or your OS equivalent, to create and manage profiles), then download and install latest firefox trunk.
Once you're done, to get back to the stable version, just install the official firefox release and lauch the profile manager again, select the original one and that's it. :)

Sorry about my bad english, and it's my first post :">

stever
24 Aug 2008, 6:28 PM
i tried last nights build but experienced a lot issues on my apps (both which work flawlessly on FF 3.0.1). one wouldnt load at all getting a 'x.el does not exist' error in ext-all.js while the other loaded fine but a few of the more advanced features failed to work. that app did seem snappier for the stuff that did work though which was nice.

im curious what other's are experiencing with 3.1 and extjs.

https://bugzilla.mozilla.org/show_bug.cgi?id=451906

The temp solution is to not compile templates. I have a 3.1 detector in my branch and have the template not compile if Fx 3.1 is the browser.

There are other issues that are JIT specific, but that is another post...

nlotz
25 Aug 2008, 12:21 AM
Please keep in mind that it's just a nightly build. I don't think there is much sense in worrying about possible incompatibilities, yet. The Ext-Team has proven numerous times that they know how to handle a browser release ...

ENEMYoftheSUN
25 Aug 2008, 4:56 PM
Hello

As you can see here : http://forums.mozillazine.org/viewtopic.php?f=23&t=815845&sid=fd204a0e19f4f6dc235766cc38c31ba2

The JS engine regression is fixed, and so extJS apps works again.

stever
26 Aug 2008, 9:28 AM
Please keep in mind that it's just a nightly build. I don't think there is much sense in worrying about possible incompatibilities, yet. The Ext-Team has proven numerous times that they know how to handle a browser release ...

Yes, but the Ext team is well known and thus might actually get heard in all the noise. The point of being proactive is to fix a bug in the browser rather than code around it in Ext. In this case, the bug would have eventually been found in Fx 3.1 as it was causing an error in the testsuite, but as it turns out, it looks like the bug did not cause a problem with the testsuite for Fx 3.0.2 coming out in September (code freeze is tonight! and it has yet to be applied, though it will since it is approved), and gosh darn, a lot of Ext sites would have broken that day.

As it turns out, I got heard. I also got on the IE8 beta test team, where I can file official reports, so I'll be doing some testing on that browser too (before it gets released). Right now, the beta1 is so broken I gave up. But b2 is coming this week I believe (so they say, but you know how things go).