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

Unified Diff: Source/core/workers/WorkerInspectorProxy.cpp

Issue 552323002: DevTools: log worker thread ids on the main thread when Timeline recording is enabled (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase Created 6 years, 3 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 | « Source/core/inspector/InspectorTraceEvents.cpp ('k') | Source/core/workers/WorkerThread.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/workers/WorkerInspectorProxy.cpp
diff --git a/Source/core/workers/WorkerInspectorProxy.cpp b/Source/core/workers/WorkerInspectorProxy.cpp
index 589033d0d33b884f4f1ffa30836c5ddbc3afd35b..e903ec6a481f558a6bed55ad48cdd73b26eb425c 100644
--- a/Source/core/workers/WorkerInspectorProxy.cpp
+++ b/Source/core/workers/WorkerInspectorProxy.cpp
@@ -8,6 +8,7 @@
#include "core/dom/CrossThreadTask.h"
#include "core/inspector/InspectorInstrumentation.h"
+#include "core/inspector/InspectorTraceEvents.h"
#include "core/inspector/WorkerInspectorController.h"
#include "core/workers/WorkerThread.h"
#include "platform/TraceEvent.h"
@@ -86,16 +87,11 @@ void WorkerInspectorProxy::sendMessageToInspector(const String& message)
m_workerThread->interruptAndDispatchInspectorCommands();
}
-static void dispatchWriteTimelineStartedEvent(ExecutionContext* context, const String& sessionId)
-{
- TRACE_EVENT_INSTANT1(TRACE_DISABLED_BY_DEFAULT("devtools.timeline"), "TracingStartedInWorker", "sessionId", sessionId.utf8());
-}
-
void WorkerInspectorProxy::writeTimelineStartedEvent(const String& sessionId)
{
if (!m_workerThread)
return;
- m_workerThread->postTask(createCrossThreadTask(dispatchWriteTimelineStartedEvent, String(sessionId)));
+ TRACE_EVENT_INSTANT1(TRACE_DISABLED_BY_DEFAULT("devtools.timeline"), "TracingSessionIdForWorker", "data", InspectorTracingSessionIdForWorkerEvent::data(sessionId, m_workerThread));
}
} // namespace blink
« no previous file with comments | « Source/core/inspector/InspectorTraceEvents.cpp ('k') | Source/core/workers/WorkerThread.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698