summaryrefslogtreecommitdiffstats
path: root/net/disk_cache/stats.cc
Commit message (Collapse)AuthorAgeFilesLines
* Disk cache: Track evictions of ga.js.rvargas@chromium.org2012-10-121-1/+7
| | | | | | | | | | | The purpose is to understand the cache behavior with very popular resources. BUG=147383 TEST=none Review URL: https://chromiumcodereview.appspot.com/11000062 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@161468 0039d316-1c4b-4281-b951-d872f2087c98
* SampleSet -> HistogramSamples which can be reused by SparseHistogramkaiwang@chromium.org2012-09-221-6/+4
| | | | | | | | BUG=139612 Review URL: https://chromiumcodereview.appspot.com/10829466 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@158166 0039d316-1c4b-4281-b951-d872f2087c98
* Introduce the ANNOTATE_LEAKING_OBJECT_PTR annotation that can be used to markglider@chromium.org2011-05-311-1/+1
| | | | | | | | | | | | heap allocated objects as intentionally leaked ones. Annotate the histograms produced by {Histogram,BooleanHistogram,LinearHistogram,CustomHistogram}::FactoryGet(), as leaked. Rename StatsHistogram::StatsHistogramFactoryGet to StatsHistogram::FactoryGet, annotate the result as leaky, update the suppressions. BUG=79322 Review URL: http://codereview.chromium.org/7071036 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@87278 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 86990 - Fix http://codereview.chromium.org/6869009 to ignore an ↵msw@chromium.org2011-05-271-1/+1
| | | | | | | | | | | | | | | | | | | existing object exactly once and land the CL again: Introduce the ANNOTATE_LEAKING_OBJECT_PTR annotation that can be used to mark heap allocated objects as intentionally leaked ones. Annotate the histograms produced by {Histogram,BooleanHistogram,LinearHistogram,CustomHistogram}::FactoryGet(), as leaked. Rename StatsHistogram::StatsHistogramFactoryGet to StatsHistogram::FactoryGet, annotate the result as leaky, update the suppressions. BUG=79322 TBR=jar Review URL: http://codereview.chromium.org/6976044 TBR=glider@chromium.org Review URL: http://codereview.chromium.org/7071035 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@86993 0039d316-1c4b-4281-b951-d872f2087c98
* Fix http://codereview.chromium.org/6869009 to ignore an existing object ↵glider@chromium.org2011-05-271-1/+1
| | | | | | | | | | | | | | | | exactly once and land the CL again: Introduce the ANNOTATE_LEAKING_OBJECT_PTR annotation that can be used to mark heap allocated objects as intentionally leaked ones. Annotate the histograms produced by {Histogram,BooleanHistogram,LinearHistogram,CustomHistogram}::FactoryGet(), as leaked. Rename StatsHistogram::StatsHistogramFactoryGet to StatsHistogram::FactoryGet, annotate the result as leaky, update the suppressions. BUG=79322 TBR=jar Review URL: http://codereview.chromium.org/6976044 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@86990 0039d316-1c4b-4281-b951-d872f2087c98
* Revert "Land http://codereview.chromium.org/6869009 for the third time."oshima@google.com2011-05-261-1/+1
| | | | | | | | | | | | | | | | | | | | | | This reverts commit d4ff483fbf60aad0b49fddd1937774edb3ba1d7e. --- Introduce the ANNOTATE_LEAKING_OBJECT_PTR annotation that can be used to mark heap allocated objects as intentionally leaked ones. Annotate the histograms produced by {Histogram,BooleanHistogram,LinearHistogram,CustomHistogram}::FactoryGet(), as leaked. Rename StatsHistogram::StatsHistogramFactoryGet to StatsHistogram::FactoryGet, annotate the result as leaky, update the suppressions. --- TBR=glider@chromium.org TEST=HistogramTest.RecordedStartupTest and WebSocketTest.ServerSentData in heapchecker bot wont hang. BUG=79322 Review URL: http://codereview.chromium.org/6962016 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@86853 0039d316-1c4b-4281-b951-d872f2087c98
* Land http://codereview.chromium.org/6869009 for the third time.glider@chromium.org2011-05-261-1/+1
| | | | | | | | | | | | | | Introduce the ANNOTATE_LEAKING_OBJECT_PTR annotation that can be used to mark heap allocated objects as intentionally leaked ones. Annotate the histograms produced by {Histogram,BooleanHistogram,LinearHistogram,CustomHistogram}::FactoryGet(), as leaked. Rename StatsHistogram::StatsHistogramFactoryGet to StatsHistogram::FactoryGet, annotate the result as leaky, update the suppressions. BUG=79322 TBR=jar,willchan Review URL: http://codereview.chromium.org/7062016 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@86794 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 85898 - Re-land http://codereview.chromium.org/6869009 (except for ↵glider@chromium.org2011-05-191-1/+1
| | | | | | | | | | | | | | | | | | | | | the suppressions) Introduce the ANNOTATE_LEAKING_OBJECT_PTR annotation that can be used to mark heap allocated objects as intentionally leaked ones. Annotate the histograms produced by {Histogram,BooleanHistogram,LinearHistogram,CustomHistogram}::FactoryGet(), as leaked. Rename StatsHistogram::StatsHistogramFactoryGet to StatsHistogram::FactoryGet, annotate the result as leaky. The previous commit broke the build on Linux Heapcheck, but looks like the problem has gone now. TBR=jar,willchan BUG=79322 Review URL: http://codereview.chromium.org/7048005 TBR=glider@chromium.org Review URL: http://codereview.chromium.org/7049006 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@85905 0039d316-1c4b-4281-b951-d872f2087c98
* Re-land http://codereview.chromium.org/6869009 (except for the suppressions)glider@chromium.org2011-05-191-1/+1
| | | | | | | | | | | | | | | | Introduce the ANNOTATE_LEAKING_OBJECT_PTR annotation that can be used to mark heap allocated objects as intentionally leaked ones. Annotate the histograms produced by {Histogram,BooleanHistogram,LinearHistogram,CustomHistogram}::FactoryGet(), as leaked. Rename StatsHistogram::StatsHistogramFactoryGet to StatsHistogram::FactoryGet, annotate the result as leaky. The previous commit broke the build on Linux Heapcheck, but looks like the problem has gone now. TBR=jar,willchan BUG=79322 Review URL: http://codereview.chromium.org/7048005 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@85898 0039d316-1c4b-4281-b951-d872f2087c98
* Fix disk cache stats to include 'Open misses'joth@chromium.org2011-04-281-4/+4
| | | | | | | | | | BUG=None TEST=open chrome:net-internals and enusre Open misses is listed Review URL: http://codereview.chromium.org/6880242 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@83315 0039d316-1c4b-4281-b951-d872f2087c98
* Revert 82460 - Introduce the ANNOTATE_LEAKING_OBJECT_PTR annotation that can ↵glider@chromium.org2011-04-211-1/+1
| | | | | | | | | be used to markheap allocated objects as intentionally leaked ones.Annotate the histograms produced by {Histogram,BooleanHistogram,LinearHistogram,CustomHistogram}::FactoryGet(), as leaked.Rename StatsHistogram::StatsHistogramFactoryGet to StatsHistogram::FactoryGet, annotate the result as leaky, update the suppressions.BUG=79322Review URL: http://codereview.chromium.org/6869009 TBR=cbentzel Review URL: http://codereview.chromium.org/6873152 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@82483 0039d316-1c4b-4281-b951-d872f2087c98
* Introduce the ANNOTATE_LEAKING_OBJECT_PTR annotation that can be used to markglider@chromium.org2011-04-211-1/+1
| | | | | | | | | | | | heap allocated objects as intentionally leaked ones. Annotate the histograms produced by {Histogram,BooleanHistogram,LinearHistogram,CustomHistogram}::FactoryGet(), as leaked. Rename StatsHistogram::StatsHistogramFactoryGet to StatsHistogram::FactoryGet, annotate the result as leaky, update the suppressions. BUG=79322 Review URL: http://codereview.chromium.org/6869009 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@82460 0039d316-1c4b-4281-b951-d872f2087c98
* Use lock-free lazy initialization for static histogram referencesjar@chromium.org2011-04-051-3/+3
| | | | | | | | | | | | | | | | Make all histogram macros thread safe, and fast by again using statics to achieve performance. ...at the cost of: Leak all histograms to avoid races at shutdown. Also included leak suppression for valgrind. r=rtenneti BUG=78207 Review URL: http://codereview.chromium.org/6780035 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@80412 0039d316-1c4b-4281-b951-d872f2087c98
* More net/ method ordering.erg@google.com2011-01-261-89/+89
| | | | | | | | | BUG=68682 TEST=compiles Review URL: http://codereview.chromium.org/6339012 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@72710 0039d316-1c4b-4281-b951-d872f2087c98
* Disk cache: Add a few more histograms and stats to figurervargas@google.com2011-01-061-3/+8
| | | | | | | | | | | out why there are so many users with available cache space. BUG=none TEST=none Review URL: http://codereview.chromium.org/6020008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@70575 0039d316-1c4b-4281-b951-d872f2087c98
* net: Append base:: in the StringPrintf calls.tfarina@chromium.org2010-09-251-4/+5
| | | | | | | | | | | (Note: This is a TODO in string_util.h) BUG=None TEST=trybots Review URL: http://codereview.chromium.org/3390026 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@60555 0039d316-1c4b-4281-b951-d872f2087c98
* Disk cache: Fix the order in which we delete datarvargas@google.com2010-09-161-2/+4
| | | | | | | | | | | | | | | | | | | | | from the block files. Stress testing the cache reveals a problem with the deletion of some data from an entry: it is possible to crash in a way that the block file thinks a block is free and an entry thinks the block is in use. This CL corrects that issue. There is also some new tests and a bunch of DCHECKS added while looking for the problem, as well as adding tests to make sure that a block file is accessed only from one thread (there is no problem with the current code in that regard) BUG=55605 TEST=netunittests Review URL: http://codereview.chromium.org/3430004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@59711 0039d316-1c4b-4281-b951-d872f2087c98
* Use factory to create histograms, and refcounts to track lifetimesjar@chromium.org2009-12-061-1/+2
| | | | | | | | | | | | | | | This is CL patch 377028 by Raman Tenneti, with minor changes to make the try-bots happier. It is cleanup that better ensures lifetimes of histograms (making it harder for users to abuse them). bug=16495 (repairs leak induced by the first landing) bug=18840 (should make leaks less possible) tbr=raman.tenneti Review URL: http://codereview.chromium.org/462027 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@33933 0039d316-1c4b-4281-b951-d872f2087c98
* Use C99 standard format macros for 64-bit values.agl@chromium.org2009-06-291-1/+2
| | | | | | | | | | | | | | | | | | | Currently we have several uses of %I64d in format strings to indicate a 64-bit value. This does not work on Mac or Linux, where 'I' indicates the use of locale specific digits. Instead, we introduce base/format_macros.h which mimic the C99 standard macros for 64-bit values in a cross-platform manner. Dean pointed out that V8 is handling this themselves rather than use inttypes.h. Maybe we'll end up going down the same path but, for the moment, we'll try and do it the 'correct' way and see how it works out. http://codereview.chromium.org/147154 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19500 0039d316-1c4b-4281-b951-d872f2087c98
* Disk Cache: Second pass (and final) to allow multiple instancesrvargas@google.com2009-03-271-6/+15
| | | | | | | | | | | | | | | | | | | of BackendImpl. This cl takes care of all the histograms on the disk cache. Most of them have to be splitted in three so that we get separate data from different cache types. There are a few places where the complexity of splitting the histogram is not worth it so we just keep either all data together (if it makes sense), or just ignore data for some types of caches. note: Having multiple versions of a histogram but only one "active" for a given client is not the same as having multiple histograms working at the same time for different objects. Review URL: http://codereview.chromium.org/42682 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@12692 0039d316-1c4b-4281-b951-d872f2087c98
* Disk cache: More instrumentation for the cache.rvargas@google.com2009-03-201-0/+36
| | | | | | | | | | | | | | Now we separate data between before and after the cache is full. Also, reduce the rate at which a particular client sends data to be only once a week. The effect is that the histogram data will only have one value per client, and the same client will not be "voting" on more than one version (release) at the same time. Review URL: http://codereview.chromium.org/50063 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@12218 0039d316-1c4b-4281-b951-d872f2087c98
* Disk cache: Instead of saving the cache stats only whenrvargas@google.com2009-03-181-11/+15
| | | | | | | | | | | | the destructor is called, store them each five minutes. From the dev channel, 15% of the runs the disk cache destructor is not called, so the stats are not that reliable without this change. Review URL: http://codereview.chromium.org/42373 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@12043 0039d316-1c4b-4281-b951-d872f2087c98
* New disk cache eviction algorithm (partial implementation).rvargas@google.com2009-03-061-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | Disabled by a #def. When enabled, file format 2.1 is used, with a possible update from ver 2.0. If a version with this code disabled is run after the upgrade, it will just discard the file and go back to 2.0. We now put some of those extra list to use! Entries are separated into various lists depending on how often are used, and we keep track of previously evicted entries. If the new algorithm is not enabled, most of the code just goes through a different path (with the old code instead of the new one). One notable exception is OpenFollowingEntry, used to enumerate the entries on the cache; the code changed significantly to support the new version of the "cache iterator", but functionally should do the same as the current code. Review URL: http://codereview.chromium.org/27345 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@11145 0039d316-1c4b-4281-b951-d872f2087c98
* Use string for Histogram names since these are all ASCII anyway.dsh@google.com2009-02-241-2/+1
| | | | | | | | Wide-character literals cause problems between platforms. Review URL: http://codereview.chromium.org/28046 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@10276 0039d316-1c4b-4281-b951-d872f2087c98
* Make sure there is only one instance of the stats histogram at a given time.rvargas@google.com2008-09-261-3/+7
| | | | | | | | | BUG=2805 Review URL: http://codereview.chromium.org/4292 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@2620 0039d316-1c4b-4281-b951-d872f2087c98
* Use histograms to send interesting parts of the disk cache statistics.rvargas@google.com2008-09-241-0/+33
| | | | | | | | | | | Most of this CL deals with a derived implementation of histograms that just queries the size stats already generated by the disk cache. The exact number of buckets, and their distribution, is controlled directly by the new class and the disk cache stats code. Review URL: http://codereview.chromium.org/3069 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@2580 0039d316-1c4b-4281-b951-d872f2087c98
* Implement sync IO for the disk cache, and temporarily redirectrvargas@google.com2008-08-271-2/+1
| | | | | | | async IO to be performed synchronously. git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1414 0039d316-1c4b-4281-b951-d872f2087c98
* Use a more compact license header in source files.license.bot2008-08-241-28/+4
| | | | git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1287 0039d316-1c4b-4281-b951-d872f2087c98
* Add net to the repository.initial.commit2008-07-261-0/+258
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@14 0039d316-1c4b-4281-b951-d872f2087c98