Closed Bug 1431028 Opened 2 years ago Closed 2 years ago
Don't discard the back buffer in Client
Single Tiled Layer Buffer
When we play the full-screen video from https://www.csfd.cz/film/402192-zmensovani/videa/ , the video's progress bar will change the width every frame. Gecko uses single tiled layer for the progress bar. If the buffer doesn't have an intermediate buffer, it will be discarded at the end of painting. Then, gecko needs to allocate a new buffer again at the next frame. Here is the profile data to show the heavy task at content side. https://goo.gl/V6Ha6x And this profile skip the buffer discarding. https://perfht.ml/2Dkisjy  https://dxr.mozilla.org/mozilla-central/rev/e4107773cffb1baefd5446666fce22c4d6eb0517/gfx/layers/client/SingleTiledContentClient.cpp#339
We should only show the warning message when we have the on-white buffer. MozReview-Commit-ID: 4gzo0reYIVL
Attachment #8943179 - Flags: review?(matt.woodrow)
Comment on attachment 8943180 [details] [diff] [review] don't discard the back buffer in ClientSingleTiledLayerBuffer. I don't know why we need to discard the back buffer. If we have the changes in next frame, we will need to allocate the buffer again. In comment 0, there is a case that will change the single tile layer's content. The profile data shows that it spends a lot of time for buffer allocation and repainting. If we skip the discarding for "non-intermediate" buffer, the profile looks better. This change might increase the memory usage.
Attachment #8943180 - Flags: review?(matt.woodrow)
Attachment #8943179 - Flags: review?(matt.woodrow) → review+
Attachment #8943180 - Flags: review?(matt.woodrow) → review+
Pushed by email@example.com: https://hg.mozilla.org/integration/mozilla-inbound/rev/8a8805912145 Don't discard the back buffer in ClientSingleTiledLayerBuffer. r=mattwoodrow https://hg.mozilla.org/integration/mozilla-inbound/rev/80b5219aedd8 Move the gfx warning to the correct position. r=mattwoodrow
You need to log in before you can comment on or make changes to this bug.