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

Unified Diff: base/trace_event/trace_log.cc

Issue 2265613002: Tracing: Added some temp debug prints to investigate crbug.com/638744 (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 4 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/trace_event/trace_log.cc
diff --git a/base/trace_event/trace_log.cc b/base/trace_event/trace_log.cc
index 872cd172b2b7310ef81b40befb90c06a3e7d5a90..0c9ff0574bc8f64c0e8381fb004916c63b050daa 100644
--- a/base/trace_event/trace_log.cc
+++ b/base/trace_event/trace_log.cc
@@ -1467,6 +1467,18 @@ void TraceLog::UpdateTraceEventDuration(
TraceEvent* trace_event = GetEventByHandleInternal(handle, &lock);
if (trace_event) {
DCHECK(trace_event->phase() == TRACE_EVENT_PHASE_COMPLETE);
+ // TEMP(oysteine) to debug crbug.com/638744
+ if (trace_event->duration().ToInternalValue() != -1) {
+ DVLOG(1) << "TraceHandle: chunk_seq " << handle.chunk_seq
+ << ", chunk_index " << handle.chunk_index << ", event_index "
+ << handle.event_index;
+
+ std::string serialized_event;
+ trace_event->AppendAsJSON(&serialized_event, ArgumentFilterPredicate());
+ DVLOG(1) << "TraceEvent: " << serialized_event;
+ lock_.AssertAcquired();
+ }
+
trace_event->UpdateDuration(now, thread_now);
#if defined(OS_ANDROID)
trace_event->SendToATrace();
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698