diff options
author | jar@chromium.org <jar@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-12-30 07:31:45 +0000 |
---|---|---|
committer | jar@chromium.org <jar@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-12-30 07:31:45 +0000 |
commit | 75b7920402c6f834376a18aa1927b223c6e3eadb (patch) | |
tree | c0a770a9b85fcb09fb988ba2ff0c2eef8b994b98 /base/tracked.cc | |
parent | d3d98bc21e6fe0ea6aa0186194347a1f5e4d7be8 (diff) | |
download | chromium_src-75b7920402c6f834376a18aa1927b223c6e3eadb.zip chromium_src-75b7920402c6f834376a18aa1927b223c6e3eadb.tar.gz chromium_src-75b7920402c6f834376a18aa1927b223c6e3eadb.tar.bz2 |
Provide a quick and dirty way to reset about:objects data
To make it easier to use the about:object profiling facility,
I put in a quick/dirty way to reset all profile stats to 0 (as if
there were no births, deaths, etc.). This code is only activated
under debug builds (or if a developer inists in a private build).
These stats don't impact semantics of the browser, so the hackish
approach to clearing the data counts can't instigate a crash, and
it makes it much easier to look at changes in the stats.
While changing the code, I also added a lot of comments, and did
a few minor cleanups items.
I also officially added about:tasks as a replacement for about:objects,
as this is really how the service is used in Chrome.
r=mbelshe
Review URL: http://codereview.chromium.org/100297
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@35372 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/tracked.cc')
-rw-r--r-- | base/tracked.cc | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/base/tracked.cc b/base/tracked.cc index 1ba894b..34694bb 100644 --- a/base/tracked.cc +++ b/base/tracked.cc @@ -77,8 +77,7 @@ void Tracked::SetBirthPlace(const Location& from_here) { ThreadData* current_thread_data = ThreadData::current(); if (!current_thread_data) return; // Shutdown started, and this thread wasn't registered. - tracked_births_ = current_thread_data->FindLifetime(from_here); - tracked_births_->RecordBirth(); + tracked_births_ = current_thread_data->TallyABirth(from_here); } void Tracked::ResetBirthTime() { |