Firefox slow with degenerate SVG filter

RESOLVED FIXED in Firefox 43

Status

()

RESOLVED FIXED
3 years ago
3 years ago

People

(Reporter: roc, Assigned: roc)

Tracking

Trunk
mozilla43
Points:
---

Firefox Tracking Flags

(firefox43 fixed)

Details

(URL)

Attachments

(5 attachments)

Created attachment 8657668 [details]
test.svg

https://information-node.net/illustration1.svg renders very slowly in Firefox but not in Chrome. The problem seems to be the SVG filter, which is very complex (55 primitives). The filter is applied to just one <path> element, which is fill:none and stroke:url(#pattern6816-3) ... but <pattern id="pattern6816-3"> is empty (though we can't just optimize away filter processing for empty elements).

The filter contains, among other things, 7 <feComposite operator="arithmetic"> with all-zero k values (i.e. transparent black), and 14 <feColorMatrix type="saturate"> with values="1" (i.e. noop).
Created attachment 8657673 [details]
MozReview Request: Bug 1202317. Bail out early if RequestRect is going to do redundant work. r=mstange

Bug 1202317. Bail out early if RequestRect is going to do redundant work. r=mstange
Attachment #8657673 - Flags: review?(mstange)
Created attachment 8657674 [details]
MozReview Request: Bug 1202317. Support PodEqual over fixed-length arrays. r=Waldo

Bug 1202317. Support PodEqual over fixed-length arrays. r=Waldo
Attachment #8657674 - Flags: review?(jwalden+bmo)
Created attachment 8657675 [details]
MozReview Request: Bug 1202317. Optimize away identity ColorMatrix nodes. r=mstange

Bug 1202317. Optimize away identity ColorMatrix nodes. r=mstange
Attachment #8657675 - Flags: review?(mstange)
Created attachment 8657676 [details]
MozReview Request: Bug 1202317. Optimize feComposite type="arithmetic" with all-zero k values to transparent black. r=mstange

Bug 1202317. Optimize feComposite type="arithmetic" with all-zero k values to transparent black. r=mstange
Attachment #8657676 - Flags: review?(mstange)
The first patch is the real fix of course.
Attachment #8657673 - Flags: review?(mstange) → review+
Comment on attachment 8657673 [details]
MozReview Request: Bug 1202317. Bail out early if RequestRect is going to do redundant work. r=mstange

https://reviewboard.mozilla.org/r/18395/#review16567
Comment on attachment 8657675 [details]
MozReview Request: Bug 1202317. Optimize away identity ColorMatrix nodes. r=mstange

https://reviewboard.mozilla.org/r/18399/#review16569
Attachment #8657675 - Flags: review?(mstange) → review+
Comment on attachment 8657676 [details]
MozReview Request: Bug 1202317. Optimize feComposite type="arithmetic" with all-zero k values to transparent black. r=mstange

https://reviewboard.mozilla.org/r/18401/#review16571
Attachment #8657676 - Flags: review?(mstange) → review+
Oooops, pushed without Waldo's review. Oh well. Let's assume he'll r+ it when he's ready :-).

Updated

3 years ago
Attachment #8657674 - Flags: review?(jwalden+bmo) → review+
Comment on attachment 8657674 [details]
MozReview Request: Bug 1202317. Support PodEqual over fixed-length arrays. r=Waldo

https://reviewboard.mozilla.org/r/18397/#review16679
https://hg.mozilla.org/mozilla-central/rev/e416ad732757
https://hg.mozilla.org/mozilla-central/rev/e3a099db7378
https://hg.mozilla.org/mozilla-central/rev/76240ee211ca
https://hg.mozilla.org/mozilla-central/rev/f088e6dbb1ba
Status: NEW → RESOLVED
Last Resolved: 3 years ago
status-firefox43: affected → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla43
You need to log in before you can comment on or make changes to this bug.