posted by Thom Holwerda on Wed 17th Nov 2010 23:10 UTC, submitted by Debjit
IconThere's a bit of a ruckus on the web about how Microsoft was supposedly cheating when it comes to Internet Explorer 9's performance on benchmarks. Digitizor, as well as some enterprising readers over at HackerNews, came to the conclusion that Microsoft included code in IE9 specifically to ace the SunSpider benchmark. I was ready to write a scathing article about this, - until I loaded up the IEBlog. As it turns, it's not cheating, it's not a bug - it's an actual piece of smart code optimisation other browsers don't have yet.

A Mozilla engineer found out that Microsoft's Internet Explorer 9 did particularly well on the math-cordic benchmark in the SunSpider suite. When people over at HackerNews (comments at HackerNews: good stuff. Recommended) dove into this matter, they concluded that Microsoft must've been cheating. Naturally, I was set to write a scathing item about this, because if there's one thing I hate, it's cheating.

Obviously, the first thing I did was try and see if Microsoft had already said something about this matter. As it turns out, they did, and what they have to say about this is kind of embarrassing for those that automatically assumed Microsoft was cheating (including myself) - Redmond is not cheating, and it's not a bug either; they've implemented something called dead code elimination.

"Some of the optimizations we've made to the JavaScript interpreter/compiler in IE9 are of a type known in the compiler world as dead code elimination," the IEBlog explains, "Dead code elimination optimizations look for code that has no effect on a running program, and removes the code from the program. This has a benefit of both reducing the size of the compiled program in memory and running the program faster."

This explains why the math-cordic benchmark runs so well on IE9. "The benchmark runs an expensive loop, and then does nothing with the results; the benchmark is written exactly in a way that triggers this general optimization," they add, "Of course, the benchmark could be rewritten to avoid triggering this optimization, which would bring our performance on this specific benchmark in line with other browsers."

Of course, any sane person already knows that these silly benchmarks are, well, silly. I honestly don't give a rat's bum about how well my browser performs on these tests - I care about how fast it renders web pages, how fast it starts up, and how well-designed and responsive the interface is.

e p (5)    101 Comment(s)

Technology White Papers

See More