Save memory by culling hidden OS compositor surfaces
Categories
(Core :: Graphics: WebRender, enhancement)
Tracking
()
Tracking | Status | |
---|---|---|
firefox72 | --- | fixed |
People
(Reporter: mstange, Assigned: gw)
References
(Blocks 1 open bug)
Details
Attachments
(1 file)
(deleted),
text/x-phabricator-request
|
Details |
At the moment, regular Firefox windows have 3x overdraw: One slice with the window background, one slice inside the "iframe" item with the non-scrolling web page background color, and one slice for the scrolled content.
The former two are usually not visible, so we should not allocate memory for them. We can do this by having WebRender apply occlusion culling to OS compositor surfaces.
Assignee | ||
Updated•5 years ago
|
Assignee | ||
Comment 1•5 years ago
|
||
Documenting a couple of potential wins from discussion of this feature:
(1) We may not need the solid color optimization anymore, simplifying the WR code and native compositor interface.
(2) Saves some GPU memory on tiles that don't match the solid color optimization.
(3) Reduces native compositor surface counts.
(4) Might allow rendering with subpixel AA in some cases where we currently don't.
(5) Performance win on Draw compositor implementations (small on systems with Hi-Z, but might be large in some cases).
(6) Will be useful / required for the software WR backend, so we might as well do it here anyway.
Assignee | ||
Comment 3•5 years ago
|
||
During the visibility pass, picture caches register themselves as
occluders, if they have a valid opaque region.
During the primitive preparation pass, each tile queries if it is
occluded. If so, it skips rasterization and compositing of itself
for this frame. In this way, tiles that are always occluded never
end up allocating GPU memory for a surface.
Also add support during primitive dependency generation for opaque
images to be considered as part of the opaque backdrop region.
Comment 5•5 years ago
|
||
bugherder |
Comment 6•5 years ago
|
||
== Change summary for alert #23698 (as of Tue, 05 Nov 2019 04:05:56 GMT) ==
Improvements:
3% raptor-tp6-google-mail-firefox-cold fcp linux64-shippable-qr opt 211.58 -> 204.58
3% raptor-tp6-bing-firefox-cold fcp linux64-shippable-qr opt 266.88 -> 258.92
For up to date results, see: https://treeherder.mozilla.org/perf.html#/alerts?id=23698
Description
•