diff options
author | jar@chromium.org <jar@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-07-30 18:41:53 +0000 |
---|---|---|
committer | jar@chromium.org <jar@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-07-30 18:41:53 +0000 |
commit | 9e9999d8f45d81bb0520de7cf8a77574fe60a640 (patch) | |
tree | 6a5fd2d6ae2da77dc260609f10ad354567991ae4 /base/tracking_info.cc | |
parent | da4ce91a27f49bd871ac0175f864a24b3273f9c2 (diff) | |
download | chromium_src-9e9999d8f45d81bb0520de7cf8a77574fe60a640.zip chromium_src-9e9999d8f45d81bb0520de7cf8a77574fe60a640.tar.gz chromium_src-9e9999d8f45d81bb0520de7cf8a77574fe60a640.tar.bz2 |
Support profiling of tasks run as sequenced_tasks
Mimic code seen in message_loop.cc (since these tasks are run on named
threads) to support tracking of sequenced worker pool runs of tasks.
We surround the *.Run() method with a call to get the time before we
start, and then call to tally the time it took to run after task.Run()
returns.
r=brettw
BUG=139035
Review URL: https://chromiumcodereview.appspot.com/10825022
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@148986 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/tracking_info.cc')
-rw-r--r-- | base/tracking_info.cc | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/base/tracking_info.cc b/base/tracking_info.cc index 7ac4221..0b091f8 100644 --- a/base/tracking_info.cc +++ b/base/tracking_info.cc @@ -1,13 +1,18 @@ -// Copyright (c) 2011 The Chromium Authors. All rights reserved. +// Copyright (c) 2012 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #include "base/tracking_info.h" +#include <stddef.h> #include "base/tracked_objects.h" namespace base { +TrackingInfo::TrackingInfo() + : birth_tally(NULL) { +} + TrackingInfo::TrackingInfo( const tracked_objects::Location& posted_from, base::TimeTicks delayed_run_time) |