mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-14 05:45:37 +00:00
Bug 1462784 - Remove EVENTS category. r=njn
Categories are useful to indicate: This much % of time was spent in this category. The EVENTS category isn't a very good match for this. This category is currently only set on labels of functions that handle the processing of an event. But those functions are usually closer to the base of the stack, and the actual CPU work during the processing of an event is usually in another category closer to the top of the stack, e.g. in JS if we're running an event handler, or in LAYOUT if we're hit testing the position of the event. This changeset removes the EVENTS category and replaces all uses of it with the OTHER category. MozReview-Commit-ID: JPm5hQiBkvp --HG-- extra : rebase_source : fb1ff20aeebb7ac494227e62ba2101039578808c
This commit is contained in:
parent
f6174e54cf
commit
be4332c903
@ -720,7 +720,7 @@ nsDOMWindowUtils::SendMouseEventToWindow(const nsAString& aType,
|
||||
uint32_t aIdentifier,
|
||||
uint8_t aOptionalArgCount)
|
||||
{
|
||||
AUTO_PROFILER_LABEL("nsDOMWindowUtils::SendMouseEventToWindow", EVENTS);
|
||||
AUTO_PROFILER_LABEL("nsDOMWindowUtils::SendMouseEventToWindow", OTHER);
|
||||
|
||||
return SendMouseEventCommon(aType, aX, aY, aButton, aClickCount, aModifiers,
|
||||
aIgnoreRootScrollFrame, aPressure,
|
||||
|
@ -508,7 +508,7 @@ nsFrameMessageManager::SendMessage(JSContext* aCx,
|
||||
"Should not have parent manager in content!");
|
||||
|
||||
AUTO_PROFILER_LABEL_DYNAMIC_LOSSY_NSSTRING(
|
||||
"nsFrameMessageManager::SendMessage", EVENTS, aMessageName);
|
||||
"nsFrameMessageManager::SendMessage", OTHER, aMessageName);
|
||||
|
||||
if (sSendingSyncMessage && aIsSync) {
|
||||
// No kind of blocking send should be issued on top of a sync message.
|
||||
|
@ -794,7 +794,7 @@ EventDispatcher::Dispatch(nsISupports* aTarget,
|
||||
EventDispatchingCallback* aCallback,
|
||||
nsTArray<EventTarget*>* aTargets)
|
||||
{
|
||||
AUTO_PROFILER_LABEL("EventDispatcher::Dispatch", EVENTS);
|
||||
AUTO_PROFILER_LABEL("EventDispatcher::Dispatch", OTHER);
|
||||
|
||||
NS_ASSERTION(aEvent, "Trying to dispatch without WidgetEvent!");
|
||||
NS_ENSURE_TRUE(!aEvent->mFlags.mIsBeingDispatched,
|
||||
|
@ -1273,7 +1273,7 @@ EventListenerManager::HandleEventInternal(nsPresContext* aPresContext,
|
||||
nsAutoString typeStr;
|
||||
(*aDOMEvent)->GetType(typeStr);
|
||||
AUTO_PROFILER_LABEL_DYNAMIC_LOSSY_NSSTRING(
|
||||
"EventListenerManager::HandleEventInternal", EVENTS, typeStr);
|
||||
"EventListenerManager::HandleEventInternal", OTHER, typeStr);
|
||||
|
||||
uint16_t phase = (*aDOMEvent)->EventPhase();
|
||||
profiler_add_marker(
|
||||
|
@ -4182,7 +4182,7 @@ CreateMouseOrPointerWidgetEvent(WidgetMouseEvent* aMouseEvent,
|
||||
{
|
||||
WidgetPointerEvent* sourcePointer = aMouseEvent->AsPointerEvent();
|
||||
if (sourcePointer) {
|
||||
AUTO_PROFILER_LABEL("CreateMouseOrPointerWidgetEvent", EVENTS);
|
||||
AUTO_PROFILER_LABEL("CreateMouseOrPointerWidgetEvent", OTHER);
|
||||
|
||||
nsAutoPtr<WidgetPointerEvent> newPointerEvent;
|
||||
newPointerEvent =
|
||||
|
@ -2520,7 +2520,7 @@ ContentChild::RecvAsyncMessage(const nsString& aMsg,
|
||||
const ClonedMessageData& aData)
|
||||
{
|
||||
AUTO_PROFILER_LABEL_DYNAMIC_LOSSY_NSSTRING(
|
||||
"ContentChild::RecvAsyncMessage", EVENTS, aMsg);
|
||||
"ContentChild::RecvAsyncMessage", OTHER, aMsg);
|
||||
|
||||
CrossProcessCpowHolder cpows(this, aCpows);
|
||||
RefPtr<nsFrameMessageManager> cpm =
|
||||
|
@ -2304,7 +2304,7 @@ TabChild::RecvAsyncMessage(const nsString& aMessage,
|
||||
const ClonedMessageData& aData)
|
||||
{
|
||||
AUTO_PROFILER_LABEL_DYNAMIC_LOSSY_NSSTRING(
|
||||
"TabChild::RecvAsyncMessage", EVENTS, aMessage);
|
||||
"TabChild::RecvAsyncMessage", OTHER, aMessage);
|
||||
|
||||
CrossProcessCpowHolder cpows(Manager(), aCpows);
|
||||
if (!mTabChildGlobal) {
|
||||
|
@ -1672,7 +1672,7 @@ TabParent::RecvSyncMessage(const nsString& aMessage,
|
||||
nsTArray<StructuredCloneData>* aRetVal)
|
||||
{
|
||||
AUTO_PROFILER_LABEL_DYNAMIC_LOSSY_NSSTRING(
|
||||
"TabParent::RecvSyncMessage", EVENTS, aMessage);
|
||||
"TabParent::RecvSyncMessage", OTHER, aMessage);
|
||||
|
||||
StructuredCloneData data;
|
||||
ipc::UnpackClonedMessageDataForParent(aData, data);
|
||||
@ -1692,7 +1692,7 @@ TabParent::RecvRpcMessage(const nsString& aMessage,
|
||||
nsTArray<StructuredCloneData>* aRetVal)
|
||||
{
|
||||
AUTO_PROFILER_LABEL_DYNAMIC_LOSSY_NSSTRING(
|
||||
"TabParent::RecvRpcMessage", EVENTS, aMessage);
|
||||
"TabParent::RecvRpcMessage", OTHER, aMessage);
|
||||
|
||||
StructuredCloneData data;
|
||||
ipc::UnpackClonedMessageDataForParent(aData, data);
|
||||
@ -1711,7 +1711,7 @@ TabParent::RecvAsyncMessage(const nsString& aMessage,
|
||||
const ClonedMessageData& aData)
|
||||
{
|
||||
AUTO_PROFILER_LABEL_DYNAMIC_LOSSY_NSSTRING(
|
||||
"TabParent::RecvAsyncMessage", EVENTS, aMessage);
|
||||
"TabParent::RecvAsyncMessage", OTHER, aMessage);
|
||||
|
||||
StructuredCloneData data;
|
||||
ipc::UnpackClonedMessageDataForParent(aData, data);
|
||||
|
@ -174,7 +174,7 @@ nsIContentChild::RecvAsyncMessage(const nsString& aMsg,
|
||||
const ClonedMessageData& aData)
|
||||
{
|
||||
AUTO_PROFILER_LABEL_DYNAMIC_LOSSY_NSSTRING(
|
||||
"nsIContentChild::RecvAsyncMessage", EVENTS, aMsg);
|
||||
"nsIContentChild::RecvAsyncMessage", OTHER, aMsg);
|
||||
|
||||
CrossProcessCpowHolder cpows(this, aCpows);
|
||||
RefPtr<nsFrameMessageManager> cpm = nsFrameMessageManager::GetChildProcessManager();
|
||||
|
@ -249,7 +249,7 @@ nsIContentParent::RecvSyncMessage(const nsString& aMsg,
|
||||
nsTArray<ipc::StructuredCloneData>* aRetvals)
|
||||
{
|
||||
AUTO_PROFILER_LABEL_DYNAMIC_LOSSY_NSSTRING(
|
||||
"nsIContentParent::RecvSyncMessage", EVENTS, aMsg);
|
||||
"nsIContentParent::RecvSyncMessage", OTHER, aMsg);
|
||||
|
||||
CrossProcessCpowHolder cpows(this, aCpows);
|
||||
RefPtr<nsFrameMessageManager> ppm = mMessageManager;
|
||||
@ -271,7 +271,7 @@ nsIContentParent::RecvRpcMessage(const nsString& aMsg,
|
||||
nsTArray<ipc::StructuredCloneData>* aRetvals)
|
||||
{
|
||||
AUTO_PROFILER_LABEL_DYNAMIC_LOSSY_NSSTRING(
|
||||
"nsIContentParent::RecvRpcMessage", EVENTS, aMsg);
|
||||
"nsIContentParent::RecvRpcMessage", OTHER, aMsg);
|
||||
|
||||
CrossProcessCpowHolder cpows(this, aCpows);
|
||||
RefPtr<nsFrameMessageManager> ppm = mMessageManager;
|
||||
@ -331,7 +331,7 @@ nsIContentParent::RecvAsyncMessage(const nsString& aMsg,
|
||||
const ClonedMessageData& aData)
|
||||
{
|
||||
AUTO_PROFILER_LABEL_DYNAMIC_LOSSY_NSSTRING(
|
||||
"nsIContentParent::RecvAsyncMessage", EVENTS, aMsg);
|
||||
"nsIContentParent::RecvAsyncMessage", OTHER, aMsg);
|
||||
|
||||
CrossProcessCpowHolder cpows(this, aCpows);
|
||||
RefPtr<nsFrameMessageManager> ppm = mMessageManager;
|
||||
|
@ -197,10 +197,9 @@ class ProfilingStackFrame
|
||||
NETWORK,
|
||||
GRAPHICS,
|
||||
STORAGE,
|
||||
EVENTS,
|
||||
|
||||
FIRST = OTHER,
|
||||
LAST = EVENTS,
|
||||
LAST = STORAGE,
|
||||
};
|
||||
|
||||
static_assert(uint32_t(Category::LAST) <= (UINT32_MAX >> uint32_t(Kind::KIND_BITCOUNT)),
|
||||
|
@ -752,7 +752,7 @@ nsViewManager::DispatchEvent(WidgetGUIEvent *aEvent,
|
||||
nsView* aView,
|
||||
nsEventStatus* aStatus)
|
||||
{
|
||||
AUTO_PROFILER_LABEL("nsViewManager::DispatchEvent", EVENTS);
|
||||
AUTO_PROFILER_LABEL("nsViewManager::DispatchEvent", OTHER);
|
||||
|
||||
WidgetMouseEvent* mouseEvent = aEvent->AsMouseEvent();
|
||||
if ((mouseEvent &&
|
||||
|
@ -707,7 +707,7 @@ nsAppShell::ProcessNextNativeEvent(bool mayWait)
|
||||
{
|
||||
EVLOG("nsAppShell::ProcessNextNativeEvent %d", mayWait);
|
||||
|
||||
AUTO_PROFILER_LABEL("nsAppShell::ProcessNextNativeEvent", EVENTS);
|
||||
AUTO_PROFILER_LABEL("nsAppShell::ProcessNextNativeEvent", OTHER);
|
||||
|
||||
mozilla::UniquePtr<Event> curEvent;
|
||||
|
||||
@ -726,7 +726,7 @@ nsAppShell::ProcessNextNativeEvent(bool mayWait)
|
||||
}
|
||||
|
||||
AUTO_PROFILER_LABEL("nsAppShell::ProcessNextNativeEvent:Wait",
|
||||
EVENTS);
|
||||
OTHER);
|
||||
mozilla::HangMonitor::Suspend();
|
||||
|
||||
curEvent = mEventQueue.Pop(/* mayWait */ true);
|
||||
|
@ -400,7 +400,7 @@ void
|
||||
nsAppShell::ProcessGeckoEvents(void* aInfo)
|
||||
{
|
||||
NS_OBJC_BEGIN_TRY_ABORT_BLOCK;
|
||||
AUTO_PROFILER_LABEL("nsAppShell::ProcessGeckoEvents", EVENTS);
|
||||
AUTO_PROFILER_LABEL("nsAppShell::ProcessGeckoEvents", OTHER);
|
||||
|
||||
nsAppShell* self = static_cast<nsAppShell*> (aInfo);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user