• On CHOW: Why is ginger ale so popular on planes?
advertisement
March 1, 2010 7:26 AM PST

Elements of Firefox overhaul arrive for testing

by Stephen Shankland

Mozilla, faced with new competitive pressures, has begun work on three separate, significant changes to Firefox.

First is a new JavaScript engine that--with a transfusion from the project behind Apple's Safari--should run Web-based programs at least 30 percent faster. Second is a new graphics engine for Windows that will take advantage of hardware acceleration for graphics and text. And third is a programming tool to help bring to fruition a new system for Firefox add-ons.

Mozilla made notable gains against the dominant Internet Explorer since Firefox's launch five years ago, but for much of that time, Microsoft's browser barely budged. Now Google's Chrome has burst onto the scene, Apple is marketing Safari for Windows as well as Mac OS X, Opera development is moving fast, and, potentially most significantly, Microsoft is showing signs of serious interest in rejuvenating IE.

Firefox could use a shot in the arm, too. Its share of global browser usage crested in November at 24.7 percent, according to Net Applications, and has slid to 24.2 percent according to preliminary statistics for February released Monday. In that same period, Chrome grew from 3.9 percent to 5.6 percent.

Mozilla has made several significant changes to Firefox in the past year, bringing an array of new features into versions 3.5 and 3.6 and working on a "Lorentz" update designed to reduce crashes stemming from plug-ins such as Adobe Systems' Flash Player. Now a new generation of ideas, although still in rough form, are moving toward real-world use.

JavaScript overhaul
Mozilla deserves some credit for getting the race for faster JavaScript into higher gear, and its TraceMonkey engine was competitive in its time. But it's been surpassed by Chrome's V8 and Safari's Nitro, while the new Carakan engine in Opera 10.5 beta has the potential to match and perhaps beat all the contenders.

All this is important because JavaScript accounts for ever-larger amounts of browser processing. Web pages feature increasingly sophisticated user interfaces largely written in JavaScript. And new standards let browsers perform background processing tasks as well, opening the door for even more advanced Web pages and Web applications.

Thus was born a Mozilla project called JaegerMonkey.

Mozilla programmers concluded that Firefox's JavaScript engine could speed up code by converting some frequently used tasks into high-speed software compiled to run in a processor's native language rather than interpreting the higher-level JavaScript instructions. The problem was when this tracing process wouldn't kick in or was thrown off, JaegerMonkey programmer David Anderson said in a blog post Friday.

"What we've found is that when tracing works, we're faster than the generic approach. But when tracing fails, we have to fall back to our old-school interpreter. At that point your JavaScript runs about as fast as it would in 2007-2008 (i.e. before Firefox 3.5, Safari 4, Chrome, etc)," Anderson said. "That's not acceptable, and we need to fix that."

JaegerMonkey is designed to get the best of both worlds. "Why couldn't we trace and keep going super awesome fast, and when tracing fails, fall back to still really fast?" he asked. "Our new project, JaegerMonkey (or JägerMonkey), has exactly this in mind...We've barely started and the results are already really promising."

According to JaegerMonkey programmer David Mandelin's description, Mozilla decided to build on the Nitro JavaScript engine for the new elements.

"We decided to import the assembler from Apple's open-source Nitro JavaScript JIT [just-in-time compiler]," Mandelin said in the blog. "We know it's simple and fast from looking at it before (I did measurements that showed it was very fast at compiling regular expressions), it's open-source, and it's well-designed C++, so it was a great fit."

Tests with the SunSpider JavaScript benchmark show JaegerMonkey to be significantly faster. With the Nitro infusion, but no optimization work yet, Anderson's test show a 30 percent speedup on 32-bit x86 systems, and a 45 percent speedup on 64-bit x86 systems, Anderson said.

However, JaegerMonkey is still a couple steps away even from mainstream beta testing. The source code can be downloaded, but it's not yet built into Mozilla's nightly "Minefield" build of the Firefox prototype.

Direct2D acceleration
Another significant Mozilla change, support for Microsoft's Direct2D technology for accelerated text and graphics, is now in that nightly build. This means it will see much heavier real-world testing, even though it's still not in an official beta.

The Direct2D and related DirectWrite interfaces tap into computers' graphics processing chips for handling many display tasks in Windows Vista and Windows 7. One change is that typeface antialiasing, which smooths curves to get rid of jagged, pixilated edges of font characters, operates over two dimensions instead of just one with earlier technology.

"The fonts look really great with DirectWrite enabled. Really great," said Mozilla's Asa Dotzler, describing his results in a blog post Saturday.

Not a lot is known about Internet Explorer 9, currently under development, but Direct2D support is definitely a feature. In a Microsoft IE9 demonstration in 2009, the browser prototype showed dramatic speed improvement in some graphics chores such as panning around online maps.

Mozilla's ambition is to beat Microsoft to the party with Direct2D support, but the technology change is significant.

"Some extensions like Stylish and AdBlock Plus may break the new features," Dotzler cautioned. And Direct2D is not enabled by default; Dotzler supplies instructions for those keen on trying it out.

JetPack SDK
Another change coming to Firefox is a new extensions foundation called Jetpack. Mozilla hopes the new system will be easier for programmers to use and less disruptive for Firefox users to manage--no reboots are required to install or update the add-ons, for example.

But the present JetPack prototype still requires some programming chops to use. Now Mozilla is trying to ease that difficulty through release of a software development kit (SDK).

"We've just released the first release candidate of the Jetpack SDK 0.1," Jetpack team member Atul Varma said in a mailing list announcement Saturday. It's still very rough, though.

"Right now, this SDK is for people who know how to use a command-line shell, as the development tools are only usable from there." Varma said. "We're also working on a Web-based development environment called FlightDeck that will make it even easier to collaborate and build real Firefox extensions...but that's not ready quite yet."

JetPack is conceptually similar to Chrome's Web-technology extensions system, but Chrome's has just arrived for Windows and, in beta form, for Mac OS X and Linux. Mozilla, though, has just released a final JetPack prototype plug-in, version 0.8, and now is working on preparing a different package called JetPack Reboot that's intended to be actually built in to Firefox.

Add-ons are an important advantage for Firefox. Programmers over the years have build thousands of them for various tasks, letting people with a particular need customize the browser without bogging it down for others who don't want that feature. Mozilla also is working on making the current add-on foundation, called XUL, work without needing browser restarts.

Individually, each of the three elements is notable but probably not enough to significantly improve Firefox's fortunes. Collectively, they show Mozilla isn't complacent and is committed to keeping Firefox competitive.

Stephen Shankland writes about a wide range of technology and products, but has a particular focus on browsers and digital photography. He joined CNET News in 1998 and since then also has covered Google, Yahoo, servers, supercomputing, Linux and open-source software, and science. E-mail Stephen, follow him on Twitter at http://www.twitter.com/stshank, or contact him through Google Buzz.
Recent posts from Deep Tech
Samsung Galaxy Tab: An Android contender
Toshiba debuts Android-powered Folio 100 tablet
TI reveals new, teensy projector chip
SD revamp to triple flash card speeds in 2012
Two years on, Chrome reshapes browser market
Samsung: Galaxy Tab has leg up on Apple iPad
Sony shows 3D laptop due in 2011
Sony announces cloud-based music service
advertisement
CNET River
  • caro: I made it! RT @ohhleary: Last course of dinner: Icebox Chocolate Cake with Bar Harbor Cadillac Mountain Stout http://plixi.com/p/43341618

  • loricnet: Or at least raw+JPG RT @Photocritic: Friends don't let friends shoot JPG. pick up your camera right now, switch it to RAW, never change it.

  • jetscott: Take a look at the Patriots' final roster, then tell me how exactly they're supposed to win the AFC East.

  • danackerman: At the Film Forum, about to see The Tinger, presented in original "Percepto" format http://yfrog.com/4blmscj

  • caro: Time for an authentic @ohhleary local beer tasting http://twitpic.com/2lbp82

  • stshank: Useful tips via John Nack on optimum Photoshop setup (memory, efficiency, history tweaks, scratch disks...) http://bit.ly/aFFznW

  • stshank: Google showing nice Geoeye satellite photos of Burning Man http://bit.ly/9YEBVf

  • Rafe: Why does The City feel different today? Oh, right: The Burners are out of town.

  • briancooley: G37 convertible vid is up: http://goo.gl/HjKo. Nice car with one big, er, small dealbreaker.

  • briancooley: G37 convertible video is up: http://bit.ly/linkxx Fun car with one big, er, small dealbreaker.

  • caro: I'm at Oak Pond Brewing Co. w/ @mbaratz. http://4sq.com/aQRHDh

  • natalidelconte: My E3 special is online! A little late but still a fun gaming show, hosted by yours truly when I was SUPER pregnant: http://bit.ly/aSwN3x

  • b1g1nj4p4n: Donating blood and sitting next to another Rosenblatt. Was going to introduce myself but he sounds like an even bigger dork than I am

  • caro: Annual buttermilk pancake gala at the barn. Next year, we'll make commemorative t-shirts. http://twitpic.com/2l77s0

  • loricnet: RT @jfleck: RT @jdub: When asked why he writes Strong Female Characters, Joss Whedon said, "Because you're still asking me that question."

  • jetscott: Suddenly my tweetstream became all Kanye...turn off the tap!

  • natalidelconte: I also dreamed that I was almost eaten by an iguana. I choose to ignore both dreams.

Chrome reshapes the browser market

The influence that Google's browser has had on the market is broader than its actual use. On Chrome's second anniversary, Google releases the sixth stable version.

Apple rolls out new iPods, social iTunes

A new version of Apple TV is also coming soon, as Apple follows its usual September playbook in refreshing its iPod lineup and the iTunes software.
• Roundup: New iPods, iTunes, TV?

About Deep Tech

Stephen Shankland, who's covered the computing industry since 1998 and was a science reporter before that, here delves into a wide range of technology trends and offers hands-on tests. His particular interests include Web browsers, cameras, standards, research, science, and start-ups.

Add this feed to your online news reader

Deep Tech topics

advertisement

Inside CNET News

Scroll Left Scroll Right