Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(216)

Unified Diff: components/timers/alarm_timer_chromeos.cc

Issue 1237283006: Extract trace from TaskAnnotator::RunTask to its call sites (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: components/timers/alarm_timer_chromeos.cc
diff --git a/components/timers/alarm_timer_chromeos.cc b/components/timers/alarm_timer_chromeos.cc
index 341818a60d736fcbce8b1cea6a8838f2dc863ada..fd785927a601a35915083ed778da70b09998f4b8 100644
--- a/components/timers/alarm_timer_chromeos.cc
+++ b/components/timers/alarm_timer_chromeos.cc
@@ -428,9 +428,18 @@ void AlarmTimer::OnTimerFired() {
else
Stop();
+ TRACE_EVENT_WITH_MEMORY_TAG2(
danakj 2015/07/15 18:03:23 You want to cover the time in this function right?
+ "toplevel",
+ "AlarmTimer::OnTimerFired",
+ pending_task.posted_from.function_name(), // Name for memory tracking.
+ "src_file",
+ pending_task.posted_from.file_name(),
+ "src_func",
+ pending_task.posted_from.function_name());
+
// Now run the user task.
base::MessageLoop::current()->task_annotator()->RunTask(
- "AlarmTimer::Reset", "AlarmTimer::OnTimerFired", *pending_user_task);
+ "AlarmTimer::Reset", *pending_user_task);
}
OneShotAlarmTimer::OneShotAlarmTimer() : AlarmTimer(false, false) {

Powered by Google App Engine
This is Rietveld 408576698