diff options
author | jbates@chromium.org <jbates@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-10-03 17:51:25 +0000 |
---|---|---|
committer | jbates@chromium.org <jbates@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-10-03 17:51:25 +0000 |
commit | 19d8a90fbc1fd7c26a873dc84fcbc875c509cf11 (patch) | |
tree | fc4334d1a7764649899ee6bbfef21c347f1a11fb /base/message_loop.h | |
parent | e4a2d08560a6853ce728c142ee71a104f14acea0 (diff) | |
download | chromium_src-19d8a90fbc1fd7c26a873dc84fcbc875c509cf11.zip chromium_src-19d8a90fbc1fd7c26a873dc84fcbc875c509cf11.tar.gz chromium_src-19d8a90fbc1fd7c26a873dc84fcbc875c509cf11.tar.bz2 |
Add trace code to track all posted tasks in message_loop and WorkerThreads (non-official builds only).
It's very helpful to understand what chrome is doing at runtime. Sometimes a thread in chrome does something expensive that causes a frame hitch. With this change, any expensive task will show up clearly in traces, with the file/function of where the task was posted.
TEST=go to about:tracing, run a trace and notice that all tasks are traced.
Review URL: http://codereview.chromium.org/7778033
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@103740 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/message_loop.h')
-rw-r--r-- | base/message_loop.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/base/message_loop.h b/base/message_loop.h index 67980ea..fffcd2f 100644 --- a/base/message_loop.h +++ b/base/message_loop.h @@ -430,14 +430,14 @@ class BASE_EXPORT MessageLoop : public base::MessagePump::Delegate { // The time when the task should be run. base::TimeTicks delayed_run_time; + // The site this PendingTask was posted from. + tracked_objects::Location posted_from; + // Secondary sort key for run time. int sequence_num; // OK to dispatch from a nested loop. bool nestable; - - // The site this PendingTask was posted from. - const void* birth_program_counter; }; class TaskQueue : public std::queue<PendingTask> { |