Right now I have 101 tabs running, and only 6 cores in my CPU. Do you know how much context switching costs in terms of performance? Do you know what the overhead would be if I were using Chrome?
So spare me, please. When general purpose computing moves to GPUs then we'll revisit the idea of "one tab per process". Until then, out of "Chrome, many tabs, performance", pick any two, drop the other.
The context switch itself is almost trivial at that scale -- a couple hundred ns per switch, with the occurrence interval in the 10s-100s of milliseconds, depending on the CPU scheduler. The part that hurts is all the cache invalidation. Unless you're actually swapping. Then you're really hosed.
Well, that and any particularly nasty plugins (cough flash cough) that don't like many instances at once.
Which OS are you running? I have yet to see chrome on linux have any hiccups on as many tabs as I throw at it. The only time I've seen hiccups are when the X server's busy on something else or I'm short on memory.
If you're on another OS, perhaps chrome's suffering b/c it can't share GDI resources (or mac's equiv) across tabs? I'm assuming it can't, as each tab's got a different process ID.
Context switching isn't that big a deal, it's actually pretty good for responsiveness since everything isn't being serialised through a single thread. Compare/contrast animgifs on a busy Opera vs a busy Chrome - Opera will regularly freeze momentarily, presumably because of stop-the-world GC.
The bigger problem is having that many tabs open without burning through enormous amounts of memory. Chrome's at least 10x less memory-efficient than Opera in this regard, which isn't great when my Opera sessions regularly run to well over 4GB :)
You are right, your scenario is much more visible nowadays. It's just that I have in mind my old single core CPU and how Chrome managed to grind my system to a halt with only a dozen tabs.
> Most of your 101 tabs should be idle, not active, so my guess would be "not much".
Keep open in the background a few js-intensive websites (e.g. gmail, twitter) and your tabs will be flickering like the proverbial Christmas tree. Depending on your hardware, the paradigm difference can be very noticeable (also, have fun on a laptop's battery).
But Chrome - and any sensible browser, really - will scale down JS execution on pages not in the foreground; you can see this in for example Piecon (http://lipka.github.com/piecon/), which will only update the favicon in your background tab bar at half the speed (if that).
I believe that Chrome caps the number of processes that it uses, so you wouldn't actually be using 101 processes. I think it caps at something like 8, or did when Chrome first came out.
Answered the "why" somewhere below, I think you're more concerned about the "how".
Place your tab bar on the left (vertically) and make it wrap to multiple lines (or columns, in this case). I have two columns at the moment, the second one with room for more tabs. Combine this with tab stacking and you have a winner.
You can have your tab bar wrapped to multiple horizontal lines but it's not as efficient given today's widescreen monitors. On lower resolutions (e.g. laptops) it's harder to put as many tabs, but the system is the same and you can still get a decent amount open.
That sounds like a personal problem. Your brain can't possibly handle anywhere near the amount of information 101 tabs provides at once, there's no reason to do that.
I use tabs like bookmarks - sites that I might need now or a bit later. I GC them from time to time. Actual bookmarks are used for things like sending a link to myself at home using firefox sync or bookmarking sites I need to visit again and again, like docs sites, the internal bugtracker, etc. I don't open those from the bookmarks menu though, I just type in the awesome bar and firefox always shows bookmarks first, i.e. I use bookmarks as a manual way to bubble up search results in the awesome bar.
I use tabs like this too and I'm not really happy about that, I just haven't found a better alternative yet.
What usually happens is I'll be browsing and find an article/code library/inspiring web design/useful tool that I know I can make use of later in some way, but if I just bookmark it then I'll probably forget it's in there.
I have very organised bookmarks but these only work for sites I visit often and I do use tools like Evernote and Gimmebar but it still doesn't feel right.
I too browse this way, and it's not about processing all the content at once. It's about utilizing the browser's ability to remember things you can't, and establishing a workflow as you move through the tabs.
I have forum threads, stackoverflow tags, manuals, ... opened. Not exactly a read later list, although I do use tabs for that as well. I use bookmarks for things I want to save for later. Usually something I've already read (at least partially) to know it's worth saving. (I know a bookmark folder/tag would be enough)
I always hold at least two digits' worth of tabs open, usually grouped into stacks. For instance, I have a stack of music/radio related tabs (e.g. youtube), several stacks with documentation that I infrequently need, stacks with tabs that I will read sometime later in the week/month/year, stacks related to various issues in the code I am working on, and so on.
I can't be bothered to use bookmarks for these things, having tabs in stacks is much more convenient. If the browser lets me keep a lot of tabs open then I'll abuse this posibility for my personal comfort.
If we were to use your philosophy then Chrome should be limited to a certain amount of tabs by design. How about 6, the number of cores in my CPU?
But thank you for the diagnosis dr. Jobs, surely I'm holding the phone the wrong way too. Keep blaming the user.
It's not blaming the user. The user in this case is using the browser in an unintended way. It it therefore the users' own fault if the browser doesn't hold up.
If I want to ride my bike facing the wrong direction, it's not the fault of the designer that I can no longer steer. I could potentially make it work, but would it ever be reasonable for the manufacturer to add another set of handlebars on the back?
As for your comment about Apple claiming the user was holding their phone incorrectly, they did ultimately provide cases right and therefore admitting that enough users were having trouble to merit a change / fix ?
All said, you are using your browser wrong. Sorry to be the one who has to tell you.
That's a poor analogy. The situation of using so many tabs is about making the browser work harder, not in an incorrect manner. So if I was to compare that to riding a bike it would be like pedaling as fast as I could. If the bike couldn't handle it then yes, I would say it was the manufacturers fault.
The fact is the Chrome efficiently runs many tabs. This guy wants an extreme use case to be primarily supported or the browser must suck.
Supporting it would be a waste of developer time. If they run out of ways to make Chrome faster and have nothing better to do then sure, let's deal with this niche problem.
I do something similar. If I am to open too many tabs and don't really need the dev tools, i.e. doing some casual browsing, I go for Opera, or Firefox instead of Chrome. I also go for them when travelling and the battery is scarce.
Context switching costs far less than the time it takes you to press the key to switch between tabs, and is not appreciably more expensive for a process than for a thread.
So spare me, please. When general purpose computing moves to GPUs then we'll revisit the idea of "one tab per process". Until then, out of "Chrome, many tabs, performance", pick any two, drop the other.