Sunday, March 30, 2008

Webkit Winning in Dromaeo - Mozilla's JavaScript Benchmark

Benchmarking is always an interesting topic of debate and especially when you have a cult-feeling around a product, it fun to watch. With the Race to ACID3 over, there is another hot topic of discussion going on in the world of web browsers. And it's JavaScript that is in question. Dromaeo is Mozilla's JavaScript Benchmark Test and I happen to put all the popular browsers on the burner!

JavaScript is an important component in today's web. It's used all over the web and is de-facto standard for browser-side execution. It's used through a lot of frameworks like YUI, Prototype, Dojo, jQuery etc. And then there is AJAX, which uses JavaScript at its base. Thus, when you compare browsers, checking the JavaScript performance makes some sense.

Dromaeo

There are a few popular ones for testing JavaScript performance. Infact, you could even write a few of your own and test, but I would recommend one of the popular ones that try to replicate real-world experiences. There is the popular JavaScript test from Webkit called SunSpider. You can find a good comparison of the browsers on that test at CyberNet. I found Mozilla's Dromaeo to be another benchmark which seems to do a lot of things like you would do in the real-world. The following are the browser results from the benchmark.

Browser (version + build) Total Time for Test (click on the timings for detail)
Safari nighly (Webkit r31368) 1805.40ms (Total)
Firefox 3 pre-beta 5 (2008032005) 1855.20ms (Total)
Safari 3.1 (525.13) 2000.80ms (Total)
Opera 9 Beta (WinGogi: build 636) 2625.00ms (Total)
Opera 9.26 (build 8835) 4158.80ms (Total)
Firefox 2.0.0.13 (release) 7897.40ms (Total)
Internet Explorer 7 (7.0.6001.18000) Unknown (didn't have the patience)

Note: Your results may vary due to various reasons, but the ranking would nearly (tough one between WebKit & FF3) be the same.

IE7 had a hard time completing the benchmark (I couldn't wait for it to complete) and as the Mozilla Wiki on the test mentions, it is a problem with IE7. I couldn't do the test on Konqueror as my Linux box has some issues booting up.

Among other things, the test goes to show the performance increase in Firefox 3. Thus, it is the right time for Mozilla to publicize the improvement in JavaScript performance and thus, I guess they have released this benchmark. Webkit and Firefox 3 are pretty much on the heels of each other in this test. Firefox 3 has also made some progress on decreasing the memory it uses when lots of tabs are open. This should give the Mozilla team something to cheer about after they said sour grapes with not participating in the ACID3 race.

5 comments:

Anonymous said...

Very nice benchmark Sir. Should have run the test from Knoppix LiveCD if you wanted to test Konqueror, considering u love Linux so much...

Anyways, were u even expecting anything other than WebKit to win... they always had the best JavaScript!!

asadotzler@gmail.com said...

IE 7 spends forever in Base 64 Encoding and Decoding. IE 8 is somewhat better, but still pretty embarrassing. You can see the pain here: http://dromaeo.com/?id=234,236,237

- A

Anonymous said...

This one seems interesting specially considering its a Mozilla benchmark and Webkit winning!! :))

Saptarshi Purkayastha said...

Thanks Adi & Vivek for checking the blogs and commenting on it. I'll try writing some useful stories for my students like you guys...

Asa, yea thats the benchmark where IE is stuck. Anything other than IE is good at the moment :), but its ironic that it still holds the largest market share!!

Unknown said...

"Opera 9 Beta (WinGogi: build 636)"

WINGOGI?!?! The WinGogi build is the ACID3 compliant build, it should NOT be used for testing anything but standards! You should be using 9.5 beta 2.