Bug 1462784 - Annotate idle stacks in the native event loop on Windows. r?froydnj
MozReview-Commit-ID: A0c3ZLLkLUC
--- a/widget/windows/nsAppShell.cpp
+++ b/widget/windows/nsAppShell.cpp
@@ -535,16 +535,17 @@ nsAppShell::ProcessNextNativeEvent(bool
::TranslateMessage(&msg);
::DispatchMessageW(&msg);
}
} else if (mayWait) {
// Block and wait for any posted application message
mozilla::HangMonitor::Suspend();
{
+ AUTO_PROFILER_LABEL("nsAppShell::ProcessNextNativeEvent::Wait", IDLE);
AUTO_PROFILER_THREAD_SLEEP;
WinUtils::WaitForMessage();
}
}
} while (!gotMessage && mayWait);
// See DoProcessNextNativeEvent, mEventloopNestingLevel will be
// one when a modal loop unwinds.