More Efficient Memory Management

Fire up an IE7 window with 10 tabs in it and you’ll see this in your Task Manager:

A single iexplore.exe process that spawns a number of threads. The same goes for Firefox and Safari. The problem here is that if a single tab causes the process to crash, all of your open websites go with it. Chrome treats each tab as an individual process, which adds a little more overhead but the benefit is a single website won’t cause all of your other browser tabs/windows to crash.


You shouldn't lose all Chrome windows/tabs due to one misbehaving website/app

A single webpage stalling also won’t cause the rest of the tabs to stall, while the tabs in a Chrome window look physically connected, they are as independent as they get.

Chrome, as a result, will take up quite a bit of space in Task Manager:

Making each tab its own process means that you get memory back from closed tabs much quicker and much more efficiently than with other browsers. Consider this test: 1) Visit www.anandtech.com, 2) open tabs for digg.com, docs.google.com (and login) and www.facebook.com (and login), 3) Close the latter three websites.

I performed that exist test, in that order, and measured memory size after each step. The results are below:

Websites Google Chrome 0.2.149.27 Internet Explorer 7.0.6001.18000 Firefox 3.0.1 Safari 3.1.2
Just AnandTech.com 26MB 30MB 30MB 48MB
AT + Digg + Google Docs + Facebook 105MB 97MB 87MB 104MB
AT (After closing 3 tabs) 38MB 78MB 70MB 107MB

 

Just viewing AnandTech alone, Chrome ended up being the most efficient browser with a 26MB footprint compared to 30MB for Firefox 3.0.1, 30.1MB for IE7 and a whopping 48MB for Safari 3.1.2.

Adding the other three sites brings the totals up to 104MB for Chrome, 104MB for Safari, 96MB for IE7 and 87MB for FF.

It’s closing the tabs that’s the most interesting: only Chrome actually frees up memory upon closing tabs. Chrome’s footprint is still larger than its original 26MB at 38MB, but the remaining three browsers continue using at least 70MB. The argument here is that these other browsers already have memory allocated should you open additional tabs, unfortunately you can quickly run into memory fragmentation issues with the conventional approach should the new tabs require more memory than the ones you just closed.

With Chrome, each tab is its own process, when you’re done with a tab - close it and you get all your memory back right away. You get more efficient usage of memory for newly created tabs.

The independent tabs are also physically independent within the UI, you can drag any tab out of a window and into another one or make it a new window by itself.

Chrome’s multi-process approach is also theoretically better for multi-core systems since you don’t have to worry about exploiting parallelism within a process, you’ve got process-level parallelism giving you more than enough threads to distribute across many cores. Thankfully web browsing isn’t the most CPU intensive and this process-level parallelism doesn’t amount to a huge performance benefit.

Index Other Geeky Stuff
Comments Locked

105 Comments

View All Comments

  • kiroset - Wednesday, September 3, 2008 - link

    Looks like they copied the popular Firefox extension - Download Statusbar - I think I prefer that implementation

    https://addons.mozilla.org/en-US/firefox/addon/26">https://addons.mozilla.org/en-US/firefox/addon/26
  • MagicalMule - Wednesday, September 3, 2008 - link

    Maybe this has been said before, but I don't feel like reading three pages of comments.

    Where's the Opera love? It had some of these feature's, is very fast, scores highest on the Acid3 test, and was not even mentioned?

    Furthermore, I am a bit weary of anything "Google" these day's thanks to their dubious privacy practices. I can't live without Gmail, and Google as a search engine, but if there was a decent alternative that didn't track you online activities/searches the same way google does I would use it for sure. Thanks to that I'm staying away from Google Chrome.

    And of course because Firefox is better. =)
    Long live Adblock Plus!
  • Tegeril - Wednesday, September 3, 2008 - link

    Opera holds 0.71% of the browser market share. It is essentially a non-player. http://en.wikipedia.org/wiki/Usage_share_of_web_br...">http://en.wikipedia.org/wiki/Usage_share_of_web_br...
  • britz - Wednesday, September 3, 2008 - link

    and what kind of argument is that, if that page shows:

    "It is also possible to underestimate the usage share by using the number of requests, for example:

    Many browsers and download managers spoof a different user agent string to the web server to prevent erroneous or malicious browser sniffing which could result in receiving broken or incompatible code, or being completely blocked, and thus increasing the statistics for other browsers (as an example, prior to version 9, the Opera web browser had "Identify as Internet Explorer" as the default user setting)"
  • Zensen - Wednesday, September 3, 2008 - link

    Geez, I was hoping to get a comparison with opera yet here's another article that seems to ignore it. I mean from the testing I did today, the google browser seems fast and simple to use yet It was amazing how many things they did borrow from the opera.

    I read it regardless but I wasn't impressed that such a powerful and useful browser was overlooked. To those who enjoy safari, to each its own but I just don't bother with that. Having said that google has made me rethink the advantages of webkit and safari underlying structure is based on that too so I can see the similarities but as ridiculous as the logo and name is, I'd definitely choose chrome over safari even at this beta stage - both react the same way but chrome seems faster and at boot up its instanteous. It's not a revolutionary step but time will tell if its even worth considering. FF has its advantages but for ease of use and speed opera, hands down. I just don't understand why ignore opera which has its foot in mobile and console platforms.

    Hopefully Google will implement some kind of RSS reader which i found quite surprising to be missing (or at least i couldn't find the thing). Loving the all in one search bar but something sorely missing that I've enjoyed from FF3 and Opera is the URL searching 'word' strings making easier to find the address you're looking for.

    single process seems like a nice concept and it seems to leave a smaller footprint so thats always a good thing? better power saving? I'll have to test this out further before I comment further.

    History searching is clean and useful and speed dial-esque similar to opera is a fantastic use of new tab space :)

    Dev tools is a great start, similar to what i saw on safari but safari's view source sucks compared to this but FF and opera still have it hands down on dev tools that come along with it.

    I haven't tested their downloading capabilities but unlike the other browsers opera comes in built with torrent capabilities so I'll have to look further into it.

    For a simple clean browser without the geeky factor, it'll probably entice quite a few casual users - Google after all... is google and that thing called search, well you'll be hard pressed to not see people intrigued by it when they come across their site.


    <3 Opera. Bring on innovation!

  • silhrt - Wednesday, September 3, 2008 - link

    Currently, i can't even get it to work.

    Noone here at where i work can get it to work.

    Does anyone have a link to where i can get in touch with them about why?

  • MorphiusFaydal - Wednesday, September 3, 2008 - link

    Personally, I'm going to wait to try it out until I can get AdBlock and something similar to Foxmarks. And addon like ForecastFox would be nice too. :)
  • Ryan Smith - Wednesday, September 3, 2008 - link

    Unlike the boss, I'm a bit more leery of Chrome myself, both in the sense that I'm not entirely excited, and in the sense that there are some things that worry me.

    I'm not excited in the sense that it is and it isn't a new browser; it's Safari's WebKit at the core. It's going to render a lot of stuff just like Safari and just as fast as Safari. I happen to like Safari (on the iPhone at least) so this isn't a bad thing, but it also means that Chrome is definitely evolutionary and not revolutionary in the end. For that matter I'm not entirely sure where to put things in a historical context, since normally new browsers are on new rendering engines. Firefox is probably the closest parallel, but even then it was a massive gutting of Mozilla.

    As for the things that worry me:

    1) I'd really like to see a good in-depth examination of the EULA and the code, to see what goes back to Google. Google is an ad firm that makes a damn good search engine (among other things) so I'd like to know what information is going where and what it's being used for, so that I'm not being abused in the process. I have no desire to start making Google my overlord.

    2) Websites as applications scare me in general, this only furthers that, as Chrome's main purpose is to push performance and stability improvements in browsers to make them more suitable for web apps. Much of this goes with #1 since it involves relinquishing some control, but it's also a matter of bloat and overall system security. This model in essence turns the web browser in to an operating system; this is great for platform independence, but not so great for security. Operating systems are tricky beasts to write and maintain, they're quite often flawed as a result. The browser as an operating system brings many of these issues to the browser. My fear is that we end up with inherently sub-par applications that require a browser every bit as bloated and insecure as Windows is accused of being; it's a situation where there's much to lose and little to gain.

    Ultimately "active" content should be handled by the OS, that's what it's there for.

    With that said, there are plenty of interesting bits of Chrome that I'm looking forward to other browsers implementing. Record-free browsing, per-tab processes (since it looks like we're not getting rid of Flash any time soon, and Adobe can't seem to make it as stable as the browser it runs in), and faster Javascript performance are all nice things to have. And making all of this available under the BSD license is an excellent way to go, since whatever good things that may come out of Chrome can freely be taken and implemented in other browsers.

    Should Chrome ever leave beta (it is Google after all...) it's going to be worth keeping an eye on.
  • scottrick49 - Wednesday, September 3, 2008 - link

    opera has an 83 on the acid3 test
  • cousin333 - Friday, September 5, 2008 - link

    Yes (85 with latest weekly). And Chrome has 78 as the screenshot says here. But in the article, it's 74/100..

Log in

Don't have an account? Sign up now