Closed Bug 1409773 Opened 2 years ago Closed 1 year ago

webrender: re-enable ImageType_Image border-images


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




Tracking Status
firefox69 --- fixed
firefox70 --- fixed


(Reporter: Gankra, Assigned: aosmond)


(Blocks 2 open bugs)


(Keywords: perf, Whiteboard: [wr-reserve][gfx-noted])


(1 file)

This was accidentally disabled, and has since bitrotted too much to re-enable.
Whiteboard: [wr-mvp] [triage]
Priority: -- → P3
Whiteboard: [wr-mvp] [triage] → [wr-reserve]
Hi Glenn,

Since I am not familiar with this topic, I would like to ni? you about this. Could have comment for the plan for this feature? Or maybe do you know someone is better to answer? Thanks.
Flags: needinfo?(gwatson)
Transfer ni? to Ethan because he is familiar with this part.
Flags: needinfo?(ethlin)
Flags: needinfo?(gwatson)
Whiteboard: [wr-reserve] → [wr-reserve][gfx-noted]
Gradient border-images are used in the Firefox UI when there's label text at the start of the URL bar, e.g. on about:crashes or on https sites with EV certificates.
Blocks: 1337552
Oops, wrong bug.
No longer blocks: 1337552
Flags: needinfo?(ethlin)

Before this patch, we would use fallback for all border images. Now for
all but vector images we will use the WebRender border images
primitives. Vector images are an exception because the fallback is
clever in that it upscales the vector image and clips to only draw the
region it requires. This avoids artifacting but to do something similar
for WebRender as it is currently defined, we would increase our CPU and
memory footprint as we would need to produce the entire vector image
upscaled, not just the parts we need. In the future we should change
WebRender to accept different image resources for each of the segments.

Pushed by
Use WebRender instead of fallback for border raster images. r=jrmuizel

Backed out changeset 9ad9e16d94d9 (bug 1409773) for crashtest failures at 640272.html

Backout link:

Push with failures:

Log link:

Log snippet:

[task 2019-07-06T20:17:23.761Z] 20:17:23 INFO - REFTEST TEST-UNEXPECTED-FAIL | file:///builds/worker/workspace/build/tests/reftest/tests/layout/base/crashtests/640272.html == file:///builds/worker/workspace/build/tests/reftest/tests/layout/base/crashtests/640272-ref.html | image comparison, max difference: 255, number of differing pixels: 176

Flags: needinfo?(aosmond)
Pushed by
Use WebRender instead of fallback for border raster images. r=jrmuizel
Assignee: nobody → aosmond
Keywords: perf
Assignee: aosmond → aosmond
Flags: needinfo?(aosmond)
Closed: 1 year ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla70

Comment on attachment 9076254 [details]
Bug 1409773 - Use WebRender instead of fallback for border raster images.

Beta/Release Uplift Approval Request

  • User impact if declined: Pages with large border images will be slow. See bug 1556243 for an example which this patch resolves.
  • Is this code covered by automated tests?: Yes
  • Has the fix been verified in Nightly?: Yes
  • Needs manual test from QE?: No
  • If yes, steps to reproduce:
  • List of other uplifts needed: None
  • Risk to taking this patch: Medium
  • Why is the change risky/not risky? (and alternatives if risky): While the patch itself is modest, this does completely change how border images are rendered when WebRender is enabled; before we would use the fallback method. On the other hand, we have many reftests for this, and it will only affect the population which has WebRender enabled (~5% of users). It is also trivial to write a new patch to use fallback just as we have before without backing out the uplift.
  • String changes made/needed:
Attachment #9076254 - Flags: approval-mozilla-beta?
Blocks: 1556243

Comment on attachment 9076254 [details]
Bug 1409773 - Use WebRender instead of fallback for border raster images.

Improves WebRender performance for tables with large border images. Approved for 69.0b4.

Attachment #9076254 - Flags: approval-mozilla-beta? → approval-mozilla-beta+
Depends on: 1565463
See Also: → 1409774
You need to log in before you can comment on or make changes to this bug.