Closed Bug 1456561 Opened 2 years ago Closed 2 years ago

Don't send a flood of WakeSceneBuilder messages when one will do

Categories

(Core :: Graphics: WebRender, enhancement)

Other Branch
enhancement
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla61
Tracking Status
firefox61 --- fixed

People

(Reporter: kats, Assigned: kats)

References

Details

(Whiteboard: [gfx-noted])

Attachments

(1 file, 2 obsolete files)

Right now we call WakeSceneBuilder for every single task that goes into the updater queue. But sometimes that can result in a flood of unnecessary WakeSceneBuilder messages - for each updater callback we end up looping through the queue of tasks and running everything we can anyway. So additional WakeSceneBuilders are only required when the previous inflight WakeSceneBuilder has been completely processed.
Comment on attachment 8970615 [details]
Bug 1456561 - Reduce the number of WakeSceneBuilder messages.

https://reviewboard.mozilla.org/r/239376/#review245160

::: gfx/layers/apz/src/APZUpdater.cpp:362
(Diff revision 1)
>      // call to WakeSceneBuilder.
>  
> +    bool sendWakeMessage = true;
>      { // scope lock
>        MutexAutoLock lock(mQueueLock);
> +      for (const auto& i : mUpdaterQueue) {

i -> element / mapping
Attachment #8970615 - Flags: review?(botond) → review+
Attachment #8970615 - Attachment is obsolete: true
Gah. MozReview!
Attachment #8970739 - Attachment is obsolete: true
Attachment #8970739 - Flags: review?(botond)
Looks like changing the MozReview-ID back to what it was originally doesn't resurrect that patch either :/

Anyway, the only difference is I renamed `i` to `queuedTask`
Comment on attachment 8970740 [details]
Bug 1456561 - Reduce the number of WakeSceneBuilder messages.

https://reviewboard.mozilla.org/r/239478/#review245190
Attachment #8970740 - Flags: review?(botond) → review+
Pushed by kgupta@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/5934ceb73115
Reduce the number of WakeSceneBuilder messages. r=botond
https://hg.mozilla.org/mozilla-central/rev/5934ceb73115
Status: NEW → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla61
You need to log in before you can comment on or make changes to this bug.