Open Bug 1489089 Opened 7 years ago Updated 3 years ago

Display glitch on IMDB when rotating between portrait and landscape

Categories

(Core :: Graphics, defect, P3)

64 Branch
ARM
Android
defect

Tracking

()

Tracking Status
firefox62 --- wontfix
firefox63 --- wontfix
firefox64 --- wontfix
firefox65 --- affected
firefox66 --- affected

People

(Reporter: levente.sacal, Unassigned)

Details

(Whiteboard: [geckoview:p3)

Device(s): - Sony Xperia Z5 (Android 7.0.0); - Samsung S8+ (Android 8.0.0); Build(s): - Nightly 64.0a1 (2018-09-05); - Beta 63.0b3 - Release 62 Steps to reproduce: 1. Go to IMDB and watch any video 2. Rotate the device from portrait to landscape and vice-versa. Expected result: - the video rotates smoothly Actual result: - the video rotates but with a couple of glitches Notes: - the "front" IMDB page also appears for a couple of milliseconds when rotating (this is not reproducible on Release 62) Video: https://youtu.be/4JDOCHgEXqk
Chris can you triage this further?
Component: General → Audio/Video
Flags: needinfo?(cpearce)
Product: Firefox for Android → Core
Version: Firefox 64 → 64 Branch
Whiteboard: [geckoview] → [geckoview:p3

Is this Bug 1377873 and Bug 1500719?

Also, in Nightly 66.0a1 (2108-01-10) Bug 1518805 hasn't landed.

For Bug 1377873 and Bug 1500719 you need to enter in fullscreen so I don't think they are the same as this issue. Thanks.

Here's a profile of Firefox for Android Nightly 2019-01-13 on my SGS6 an the Game of Thrones trailer on IMDB.com, with multiple orientation changes:

https://perfht.ml/2HaBpYk

Note you don't need to be playing the video for the issue to appear.

The glitches appear to be caused by us reflowing when the viewport changes size due to orientation changes, and we're painting slowly after reflow too, looks like box-shadows are taking a long time to paint.

In fact, 246ms in mozilla::PresShell::ResizeReflow [1] in one of the peaks I looked at. We can spend up to 337 ms painting as well [2], I think mostly due to the box shadow.

Here's a GeckoViewExample profile:
https://perfht.ml/2Hd3sGu

GeckoViewExample actually performs prettey well, we're spending most of our time in painting, and a sometimes resize reflow is on the hot path.

Since we spend most of our time painting here, I'll move this to gfx component.

It's possible that the resize reflow still takes a non trivial amount of time... Maybe if we cached the outgoing layout upon rotation, then if we rotate back we'd be able to reuse the previous orientation's reflow if nothing in the dom or styles has changed?

dbolter: Given that this seems to not be a problem in the geckoview_example app, does this bug need to be closed WONTFIX?

[1] https://perfht.ml/2HaSXDm
[2] https://perfht.ml/2Hcxavk

Component: Audio/Video → Graphics
Flags: needinfo?(cpearce) → needinfo?(dbolter)

(In reply to Chris Pearce [:cpearce (GMT+13)] from comment #4)

dbolter: Given that this seems to not be a problem in the geckoview_example app, does this bug need to be closed WONTFIX?

I think we can close it, but do we know if this is a regression?

Flags: needinfo?(levente.sacal)
Flags: needinfo?(kbrosnan)
Flags: needinfo?(dbolter)

I will clear my needinfo as I can't help you here.

Flags: needinfo?(levente.sacal)
Priority: -- → P3
Flags: needinfo?(kbrosnan)
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.