Closed Bug 981278 Opened 10 years ago Closed 6 years ago

Chrome process paints unnecessarily while launching an application

Categories

(Firefox OS Graveyard :: General, defect, P2)

ARM
Gonk (Firefox OS)
defect

Tracking

(Not tracked)

RESOLVED WONTFIX

People

(Reporter: ting, Unassigned)

References

Details

(Keywords: perf, Whiteboard: [c=effect p= s= u=])

Attachments

(2 files)

When I worked on bug 974308 with b2g v1.3t, I noticed chrome process enters nsViewManager::ProcessPendingUpdatesForView() several times while launching an application even status bar has nothing changed. This makes application launching longer especially when it is low on memory.

Can see status bar flashing after enable "Flash repainted area".
See Also: → 974308
I captured 2 backtraces from chrome process which hit nsIFrame::InvalidateFrameSubtree() while launching application.
Great finding Ting-Yu! We enter DoProcessRestyles() that may due to some style change in the system app.

Please cc dbaron if you need help on the css side.
Tapping an application icon on Tarako:

  GeckoInputDispatcher::notifyMotion action=10(HOVER_EXIT) flags=0 count=1
  GeckoInputDispatcher::notifyMotion action=0(DOWN) flags=0 count=1
  nsAppShell::sendMouseEvent() msg=1128645728 x=0 y=0 forwardToChildren=1
  nsAppShell::sendMouseEvent() msg=302 x=293 y=66 forwardToChildren=0
  GeckoInputDispatcher::notifyMotion() action=2(MOVE) flags=0 count=1
  GeckoInputDispatcher::notifyMotion() action=2(MOVE) flags=0 count=1
  ...
  ...
  GeckoInputDispatcher::notifyMotion() action=1(UP) flags=0 count=1
  GeckoInputDispatcher::notifyMotion() action=9(HOVER_ENTER) flags=0 count=1
  GeckoInputDispatcher::notifyMotion() action=7(HOVER_MOVE) flags=0 count=1
  nsAppShell::sendMouseEvent() msg=301 x=294 y=66 forwardToChildren=0
  nsAppShell::sendMouseEvent() msg=1128645728 x=0 y=0 forwardToChildren=1
  nsAppShell::sendMouseEvent() msg=300 x=0 y=0 forwardToChildren=1

Am trying to understand why not forward DOWN/UP to children (Homescreen).
(In reply to Fabrice Desré [:fabrice] from comment #2)
> Great finding Ting-Yu! We enter DoProcessRestyles() that may due to some
> style change in the system app.
> 
> Please cc dbaron if you need help on the css side.

Ok, thanks for reminding :)
(In reply to Ting-Yu Chou [:ting] from comment #3)
>   GeckoInputDispatcher::notifyMotion action=0(DOWN) flags=0 count=1
>   nsAppShell::sendMouseEvent() msg=302 x=293 y=66 forwardToChildren=0

forwardToChildren == 0 since sendTouchEvent() passes the touch event to Homescreen and returns nsEventStatus_eConsumeNoDefault before calling sendMouseEvent(), this seems related to spec: http://goo.gl/3B5Wbq.

Not sure why the motion event is processed by both Homescreen and chrome process.
See Also: → 775403
Trying to understand how the motion events are handled by PresShell::HandleEventInternal() in b2g process. Use ">" and "<" to indicate entering/exiting a function.
I saw the same thing while phone ringing, b2g process paints several times prior Communications.
Keywords: perf
Priority: -- → P2
Whiteboard: [c=effect p= s= u=]
Firefox OS is not being worked on
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: