3 ms·
I was terribly disappointed by the performance of FF4. When releasing blockbattle.net (very JS heavy game), we knew it performed poorly in FF3.6 while flying in
by martythemaniak 16y ago
I was terribly disappointed by the performance of FF4. When releasing blockbattle.net (very JS heavy game), we knew it performed poorly in FF3.6 while flying in Chrome/Safari. We made some changes and optimizations and thought that FF4 would be at least as fast as older versions of chrome/safari but no such luck.
We now have to dedicate extra time to investigating and optimizing performance for FF4, which makes it scarily like IE - you get everything working in Chrome/Safari, then spend extra time getting it to work on other browsers like FF and IE.
- ootachi 16y agoUsually comments like yours are the result of relying on precise setTimeout()/setInterval(). Firefox has a very coarse-grained setTimeout/setInterval (it's capped at 10ms) compared to WebKit. Mozilla can't change this easily as it breaks the web and hurts power management. I just took a cursory glance at blockbattle.net's source and it may well be the problem. Thankfully, FF4 has a solution: mozRequestAnimationFrame(). This explanation [1] should be required reading for everyone doing games and animations in JS. [1]: http://weblogs.mozillazine.org/roc/archives/2010/08/mozrequestanima.html http://weblogs.mozillazine.org/roc/archives/2010/08/mozreque...