Closed Bug 1567319 Opened 5 years ago Closed 5 years ago

PayloadPresented is not called for no-op composites

Categories

(Core :: Graphics: Layers, defect, P3)

defect

Tracking

()

RESOLVED FIXED
mozilla70
Tracking Status
firefox70 --- fixed

People

(Reporter: mstange, Assigned: mstange)

Details

Attachments

(1 file)

Sometimes the compositor will detect that nothing changed on the screen and abort the composite. In that case, PayloadPresented will not be called, and payloads will stick around and their latency will be artificially high.

Conceptually, if a key press or a wheel scroll did not change anything in the onscreen rendering, we should count those no-op composites as a success: We have successfully completed the work that needed to be done in response to those events. So I think we should call PayloadPresented even if there is no compositing. The "presented" part is maybe a bit of a lie, then; it's more like "PayloadHandledToCompletion" in reality.

At the moment, for LayerManagerComposite, LayerManagerComposite::Render() is what calls PayloadPresented. No-op composites are detected in its caller, LayerManagerComposite::UpdateAndRender(), so we don't even enter Render() for no-op composites. We should probably move the call to PayloadPresented into LayerManagerComposite::UpdateAndRender().

Alternatively, we could discard all payloads that don't require compositing.

Priority: -- → P3

On IRC, Bas agreed that discarding such payloads is probably the right way to go.

This patch fixes LayerManagerComposite. I have not looked at LayerManagerMLGPU or WebRender.
The patch is on top of the patches from bug 1571253.

Assignee: nobody → mstange
Status: NEW → ASSIGNED
Attachment #9082872 - Attachment description: Bug 1567319 - Discard payloads for no-op composites. r?Bas → Bug 1567319 - Discard payloads for no-op composites. r=Bas
Pushed by mstange@themasta.com: https://hg.mozilla.org/integration/autoland/rev/3851e6be2a2d Discard payloads for no-op composites. r=bas
Status: ASSIGNED → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla70
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: