Cache Notes: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
|||
(14 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
== ToDo List == | |||
Here are some things we can investigate to gain more information about the current state of the cache: | |||
*Determine what the cache's average hit rate is. | |||
*See how performance varies by increasing the cache size. | |||
*Look into whether YouTube files are blowing out the cache. | |||
*Run a Test Pilot or a smaller experiment to gather user cache data | |||
**In order to gather info on the previous bullet points | |||
Here are some ideas for improving the cache that need to be investigated: | |||
*Consider other eviction options | |||
**Prioritize by file type, giving css and js higher priority | |||
**Evict based on "frecency", not just recency (frequency + recency) | |||
**Use Adaptive Replacement Cache algorithm: http://en.wikipedia.org/wiki/Adaptive_replacement_cache | |||
**We could consider letting servers specify "cache-priority" with resources. This leads to other issues, like fairness. | |||
*Keep dimensions of evicted image files, so layout can still render before the image data arrives across the network | |||
*Compress cache entries? | |||
**This could save space and improve I/O time | |||
*Don't throw away the entire cache when the browser crashes. | |||
And here are some miscellaneous items: | |||
*Add more info to about:cache, including hit rates and other info. | |||
== List of Other Cache Resources == | == List of Other Cache Resources == | ||
Here are some links with other documentation on the cache. | Here are some links with other documentation on the cache. | ||
*hacks.mozilla article on [http://hacks.mozilla.org/2010/05/revitalizing-caching/ revitalizing caching] | |||
*http://www.mozilla.org/projects/netlib/presentations/necko1-2002-02-18/slide11.xml | *http://www.mozilla.org/projects/netlib/presentations/necko1-2002-02-18/slide11.xml | ||
*https://developer.mozilla.org/en/HTTP_Caching_FAQ | *https://developer.mozilla.org/en/HTTP_Caching_FAQ | ||
*My [[http_cache_protocol|notes]] on the HTTP cache protocol. | |||
Here is a list of bugs filed on the cache. Many are resolved. | Here is a list of bugs filed on the cache. Many are resolved. | ||
* | *(http_cache) Meta-bug: improve HTTP cache {{bug|559729}} | ||
* | *Eliminate synchronous reads from cache (make cache reads asynchronous): {{bug|513008}} | ||
* | *Remove sync writes from current cache: {{bug|513074}} | ||
* | *Write/flush cache metadata off main-thread: {{bug|549767}} | ||
* | *xpcshell tests: assertion "mem cache leaking entries" in nsMemoryCacheDevice::Shutdown() causing abort test failed: {{bug|548406}} | ||
* | *Replace necko cache with the Google Chrome cache: {{bug|514213}} | ||
* | *Implement modern cache: {{bug|512849}} | ||
* | *Disk Cache overflow when downloading large files: {{bug|443067}} | ||
* | *Cache corruption when viewing sites with several large images (simultaneous hash collision & cache dooming by disk cache size limit): {{bug|321361}} | ||
* | * Increase default disk cache size: {{bug|193911}} | ||
* | * Figure out the max nr of entries we should store in the disk cache: {{bug|569709}} | ||
*Some files are never cached due to hash collisions which are quite common due to weak string hash function: {{bug|290032}} | |||
* Firefox stores corrupted version of cached JavaScript file (merges two files together): {{bug|355567}} | |||
* Need to teach necko to deal with channels reading and writing to a cache entry simultaniously: {{bug|446876}} |
Latest revision as of 21:23, 27 July 2010
ToDo List
Here are some things we can investigate to gain more information about the current state of the cache:
- Determine what the cache's average hit rate is.
- See how performance varies by increasing the cache size.
- Look into whether YouTube files are blowing out the cache.
- Run a Test Pilot or a smaller experiment to gather user cache data
- In order to gather info on the previous bullet points
Here are some ideas for improving the cache that need to be investigated:
- Consider other eviction options
- Prioritize by file type, giving css and js higher priority
- Evict based on "frecency", not just recency (frequency + recency)
- Use Adaptive Replacement Cache algorithm: http://en.wikipedia.org/wiki/Adaptive_replacement_cache
- We could consider letting servers specify "cache-priority" with resources. This leads to other issues, like fairness.
- Keep dimensions of evicted image files, so layout can still render before the image data arrives across the network
- Compress cache entries?
- This could save space and improve I/O time
- Don't throw away the entire cache when the browser crashes.
And here are some miscellaneous items:
- Add more info to about:cache, including hit rates and other info.
List of Other Cache Resources
Here are some links with other documentation on the cache.
- hacks.mozilla article on revitalizing caching
- http://www.mozilla.org/projects/netlib/presentations/necko1-2002-02-18/slide11.xml
- https://developer.mozilla.org/en/HTTP_Caching_FAQ
- My notes on the HTTP cache protocol.
Here is a list of bugs filed on the cache. Many are resolved.
- (http_cache) Meta-bug: improve HTTP cache bug 559729
- Eliminate synchronous reads from cache (make cache reads asynchronous): bug 513008
- Remove sync writes from current cache: bug 513074
- Write/flush cache metadata off main-thread: bug 549767
- xpcshell tests: assertion "mem cache leaking entries" in nsMemoryCacheDevice::Shutdown() causing abort test failed: bug 548406
- Replace necko cache with the Google Chrome cache: bug 514213
- Implement modern cache: bug 512849
- Disk Cache overflow when downloading large files: bug 443067
- Cache corruption when viewing sites with several large images (simultaneous hash collision & cache dooming by disk cache size limit): bug 321361
- Increase default disk cache size: bug 193911
- Figure out the max nr of entries we should store in the disk cache: bug 569709
- Some files are never cached due to hash collisions which are quite common due to weak string hash function: bug 290032
- Firefox stores corrupted version of cached JavaScript file (merges two files together): bug 355567
- Need to teach necko to deal with channels reading and writing to a cache entry simultaniously: bug 446876