Closed Bug 1677872 Opened 4 years ago Closed 4 years ago

Reduce division usage in brush shaders

Categories

(Core :: Graphics: WebRender, enhancement)

enhancement

Tracking

()

RESOLVED FIXED
85 Branch
Tracking Status
firefox85 --- fixed

People

(Reporter: lsalzman, Assigned: lsalzman)

References

(Blocks 1 open bug)

Details

(Keywords: perf-alert)

Attachments

(1 file)

We use mod() in a lot of places in the brush shaders which can generate expensive divisions. If we normalize UVs in the vertex shader, that allows us to use fract() in the fragment shader which is much cheaper.

Pushed by lsalzman@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/029ac94eb369
reduce division usage in brush shaders. r=gw
Flags: needinfo?(lsalzman)
Pushed by lsalzman@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/fc06dd6899fc
reduce division usage in brush shaders. r=gw
Flags: needinfo?(lsalzman)
Pushed by lsalzman@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/87753e6e544e
reduce division usage in brush shaders. r=gw
Status: ASSIGNED → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → 85 Branch

== Change summary for alert #27822 (as of Mon, 23 Nov 2020 12:02:50 GMT) ==

Improvements:

Ratio Suite Test Platform Options Absolute values (old vs new)
5% rasterflood_gradient windows10-64-shippable-qr e10s stylo webrender-sw 195.29 -> 204.92
5% rasterflood_gradient linux64-shippable-qr e10s stylo webrender-sw 206.58 -> 216.67
5% rasterflood_gradient windows10-64-shippable-qr e10s stylo webrender-sw 195.50 -> 204.75

For up to date results, see: https://treeherder.mozilla.org/perfherder/alerts?id=27822

You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: