Bug 1476514 dispatch ConsoleProfileWorkletRunnables to main thread rather than worklet thread r=baku
authorKarl Tomlinson <karlt+@karlt.net>
Wed, 28 Nov 2018 17:23:35 +0000
changeset 507902 80f561f7ac764d3a3b181aff4ef01dcdf4b38c67
parent 507901 32d5c8f3ca7f0eabefabd489d50d47e084d98f2a
child 507903 704371789faab7c03f3128976d8dc001608f35d5
push id1905
push userffxbld-merge
push dateMon, 21 Jan 2019 12:33:13 +0000
treeherdermozilla-release@c2fca1944d8c [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbaku
bugs1476514
milestone65.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1476514 dispatch ConsoleProfileWorkletRunnables to main thread rather than worklet thread r=baku This is consistent with ConsoleCallDataWorkletRunnable queuing and enables ConsoleProfileWorkletRunnable::RunOnMainThread() to run. Depends on D13210 Differential Revision: https://phabricator.services.mozilla.com/D13211
dom/console/Console.cpp
--- a/dom/console/Console.cpp
+++ b/dom/console/Console.cpp
@@ -1380,17 +1380,17 @@ Console::ProfileMethodInternal(JSContext
 
   if (WorkletThread::IsOnWorkletThread()) {
     RefPtr<ConsoleProfileWorkletRunnable> runnable =
       ConsoleProfileWorkletRunnable::Create(this, aMethodName, aAction, aData);
     if (!runnable) {
       return;
     }
 
-    WorkletThread::Get()->DispatchRunnable(runnable.forget());
+    NS_DispatchToMainThread(runnable.forget());
     return;
   }
 
   if (!NS_IsMainThread()) {
     // Here we are in a worker thread.
     RefPtr<ConsoleProfileWorkerRunnable> runnable =
       new ConsoleProfileWorkerRunnable(this, aMethodName, aAction, aData);