Closed Bug 1422567 Opened 7 years ago Closed 5 years ago

Crazy subreddit CSS with hundreds of text shadows is slow in WebRender

Categories

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

defect

Tracking

()

RESOLVED FIXED
Tracking Status
firefox-esr52 --- unaffected
firefox57 --- unaffected
firefox58 --- unaffected
firefox59 --- unaffected

People

(Reporter: TD-Linux, Assigned: gw)

References

(Blocks 1 open bug, )

Details

(Whiteboard: [wr-reserve])

Minimized testcase here: https://codepen.io/anon/pen/YEBLVy

Runs at ~15fps on my machine.
Apparently this is a hack to work around text-shadow not having a way to grow the outline other than blur (or alternately, no way to control the shape of the blur falloff). Here's another example of it in action, for a different use: https://eager.io/blog/smarter-link-underlines/
What's the Firefox performance without WebRender enabled?
Flags: needinfo?(tdaede)
Whiteboard: [wr-mvp] [triage] → [wr-reserve]
It's OK without WebRender - not because rendering is fast (it's even slower than with WebRender) but because scrolling and the animated css background don't cause repaints in that area of the page. (the linked page only reaches 30fps without WebRender because the animated header actually causes continuous repaints, just not to the region with the css shadows)
Flags: needinfo?(tdaede)
Found another example in the wild, with an even greater hit (runs at ~5fps when the text is in view) https://twofold.salty-salty-studios.com/
See Also: → 1463318
This seems to run ok for me on Windows Nvidia. Is it still a problem for you? What hardware?
Flags: needinfo?(tdaede)
Blocks: stage-wr-next
No longer blocks: stage-wr-trains
Actually running it at a higher resolution really slows things down.
Blocks: stage-wr-trains
No longer blocks: stage-wr-next
Flags: needinfo?(tdaede)
Priority: P2 → P3
Can confirm (Nvidia GTX 970 on Windows 10 x64), latest nightly, on a 4k monitor. Performance on text-shadow heavy pages is abominable.

The bottom of the following page is particularily bad: https://system-admin-girl.com/ (beware, anime)

Moving the firefox window to a 1080p monitor improves performance significantly, though there are still noticable jitters when beginning a scroll.
Assignee: nobody → gwatson

With picture caching enabled by default, this is running at a smooth 60 fps @ 4k on my Intel HD4600, so I think we can close this.

Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED

Can confirm, performance is perfect on the above testcases. Thanks all!

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