6 ms·
I am said Chromium developer. Let me respond to this comment from the article: """ This is not the case for Chrome: the browser keeps all the cached informatio
by hobohacker 14y ago
I am said Chromium developer.
Let me respond to this comment from the article:
"""
This is not the case for Chrome: the browser keeps all the cached information indefinitely; perhaps this is driven by some hypothetical assumptions about browsing performance, and perhaps it simply is driven by the desire to collect more information to provide you with more relevant ads. Whatever the reason, the outcome is simple: over time, cache lookups get progressively more expensive; some of this is unavoidable, and some may be made worse by a faulty hash map implementation in infinite_cache.cc.
"""
Chromium (and thereby, Google Chrome) does not cache forever. The author is clearly misled by the infinite_cache.cc file he referenced. That is our experiment file, designed to examine a theoretical "infinite" cache's performance for data gathering purposes. It doesn't actually cache the resources, but just records the keys (basically, the URL). It only runs on a small set of user browser sessions (only for users who opt-in to helping make Google Chrome better and a subset of their browsing sessions).
As my previous Google+ post mentions (thanks for the parent for linking it), we cap the cache size at 320MB. The author is simply factually incorrect about the aforementioned claim.
As for cache performance as the cache gets larger, I fully believe that it gets slower. We have data that backs up this assertion. Of course, larger caches means that more gets cached. And there are ways to restructure the cache implementation to avoid the painful latency on cache misses. While cache misses are indeed a large percent of resource requests, it is misguided to analyze the cost of cache misses in isolation. For the opposite argument about how we should be increasing cache sizes, see Steve Souders' posts: http://www.stevesouders.com/blog/2012/10/11/cache-is-king/ http://www.stevesouders.com/blog/2012/10/11/cache-is-king/, http://www.stevesouders.com/blog/2012/03/22/cache-them-if-you-can/ http://www.stevesouders.com/blog/2012/03/22/cache-them-if-yo..., etc.
The caching issues are far more complicated than described in the original post. The data is much appreciated, and we have similar data that we're looking at as we're making our decisions about caching.
- jfb 14y agoIf the hash map in infinite_cache.cc is broken, how about a footnote explaining why? The lack of specificity here was a bad blog smell, in my eyes.
- taeric 14y agoI think it was simply reflecting that the map lookup is not closer to constant, which one would have a reason to expect from a hash lookup. :)
- sdepablos 14y agoI don't know when you changed the behavior, but until a few months ago the cache was infinite. I close friend was unable to use Chrome because it took minutes - yes, minutes - to boot until we found is was a problem related with the huge cache it was maintaining.
- hobohacker 14y agoNo, we have never had an infinite cache. What is more likely is that your friend may have encountered a bug. If he has information on this issue, please file a bug at crbug.com/new and I will be happy to triage it.
- stanleydrew 14y agoNote that "huge" and "infinite" are not the same thing.
- slacka 14y agoTo set the cache to only 100MB, you can always use the "--disk-cache-size=104857600" flag. My issue with chrome is that it eats up a lot more RAM than Firefox. When doing research, I often have 30-50 tabs open. With Chrome my system runs out of physical RAM and starts thrashing. With Firefox, the UI becomes unresponsive due to it's single threaded design. I wish Chrome would start a Memshrink project like Mozilla did or Mozilla would finish with they started with electrolysis.
- thelukester 14y agoOn my 2GB netbook, chrome has gone from my preferred browser to unusable due to the high memory footprint of recent builds. One killer is the GPU process often taking 200+MB. Before giving up, and switching to FF, I tried the --disable-gpu --disable-software-rasterizer switches to disable the GPU process but that prevented videos from playing at full speed.
- Cthulhu_ 14y ago> My issue with chrome is that it eats up a lot more RAM than Firefox. When doing research, I often have 30-50 tabs open. With Chrome my system runs out of physical RAM and starts thrashing. With Firefox, the UI becomes unresponsive due to it's single threaded design. Alternatively, since you seem to be a power user, you could consider upgrading your hardware to 8 or 16 GB of memory; it's not that expensive nowadays, and given your power user status, more memory = faster computer experience = higher productivity. Or just more tabs. [old man mode] Back in the day we upgraded our computers instead of blaming software.
- emn13 14y agoThere's no need to answer FUD with FUD: Firefox's UI does not become unresponsive with increasing number of tabs. Certainly not with just 50 anyhow; I do that all the time and never notice a slowdown. The tab-closing animation is less smooth than chrome's however. And while it's certainly true chrome uses more memory per tab, I can't imagine running into that problem very easily even on somewhat outdated hardware. A 4GB system should be able to do 50 tabs normally, and how much more do you need?