Closed
Bug 768775
Opened 12 years ago
Closed 12 years ago
Gradient perf is unusably slow on test case
Categories
(Core :: Graphics, defect)
Tracking
()
RESOLVED
FIXED
mozilla17
Tracking | Status | |
---|---|---|
firefox16 | --- | fixed |
People
(Reporter: BenWa, Assigned: roc)
References
Details
(Whiteboard: [Snappy:p1])
Attachments
(4 files)
(deleted),
text/html
|
Details | |
(deleted),
patch
|
jrmuizel
:
review+
akeybl
:
approval-mozilla-aurora+
|
Details | Diff | Splinter Review |
(deleted),
patch
|
bas.schouten
:
review+
akeybl
:
approval-mozilla-aurora+
|
Details | Diff | Splinter Review |
(deleted),
patch
|
bas.schouten
:
review+
akeybl
:
approval-mozilla-aurora+
|
Details | Diff | Splinter Review |
Test case:
http://estelle.github.com/mobileperf/#slide14
Profile:
http://people.mozilla.org/~bgirard/cleopatra/?report=AMIfv96oQne_-iA9yvusK2c_xPq2XCLcoJk67PE7MsQMtNOphnzr3DxVtg7gKhAcrajRN0kiqtlfGG1z_3h66deiYF8fBZ_wqOJatXDfu3160FzwxCg3HzMk8HIfKsqE8HK_VrhkOc85Yh9nrPKpGgvLSHAhuaVeRg
We're orders of magnitude slower then chrome. There's certainly some low hanging fruits here.
Updated•12 years ago
|
Whiteboard: [Snappy]
Comment 1•12 years ago
|
||
The reason webkit is so much faster is because it draws the gradient to an image and tiles that instead of drawing a repeating gradient over the size of the entire screen.
Assignee | ||
Updated•12 years ago
|
Assignee: nobody → roc
Comment 2•12 years ago
|
||
FWIW, the webkit code is:
WebCore::GeneratedImage::drawPattern()
Assignee | ||
Comment 3•12 years ago
|
||
The problem is getting pixel-snapping and joins between tiles right.
Assignee | ||
Comment 4•12 years ago
|
||
This should make things a lot better. In all the cases of small gradients being repeated that I've seen, they have been axis-aligned linear gradients, and this optimization should kick in.
Attachment #637302 -
Flags: review?(jmuizelaar)
Reporter | ||
Comment 5•12 years ago
|
||
This patch makes a huge improvement! Not quite as good as WebKit on this page but at least the page works :).
I notice that when I'm spanning right with the arrow keys some slides disappear.
Updated•12 years ago
|
Attachment #637302 -
Flags: review?(jmuizelaar) → review+
Assignee | ||
Comment 6•12 years ago
|
||
I had tried to push this, but there were reftest failures so I backed it out:
https://tbpl.mozilla.org/?tree=Mozilla-Inbound&rev=61b94ce72be4
Assignee | ||
Comment 7•12 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/61b94ce72be4 is my attempt to fix some OSX failures, but wasn't quite enough:
https://tbpl.mozilla.org/php/getParsedLog.php?id=13153677&tree=Mozilla-Inbound&full=1
There were other failures on Windows D2D:
https://tbpl.mozilla.org/php/getParsedLog.php?id=13155509&tree=Mozilla-Inbound&full=1
These Windows failures are concerning. The basic issue is sampling. It's clearest in the linear-vertical*.html tests. The first row of pixels is generated partially by sampling the last stop of the gradient. In linear-repeat-* it's also quite obvious; there the last row of pixels is generated partially by sampling the first stop of the gradient. These artifacts are quite obvious and need to be fixed somehow.
Assignee | ||
Comment 8•12 years ago
|
||
The test failures are because Windows D2D is currently using Thebes to draw content in reftests :-(. I have a fix for the cairo-D2D code that would probably fix that, but a better approach is to fix bug 772726 so that on Tinderbox Windows D2D uses Azure to draw content in reftests.
Updated•12 years ago
|
Whiteboard: [Snappy] → [Snappy:p1]
Need to be fixed before Firefox 16 release what will support unprefixed "repeating-linear-gradient" http://hacks.mozilla.org/2012/07/aurora-16-is-out/ otherwise it will bring Firefox bad experience and tons of failures.
Assignee | ||
Comment 10•12 years ago
|
||
This reduces the effects of bug 582236.
Attachment #645581 -
Flags: review?(bas.schouten)
Assignee | ||
Comment 11•12 years ago
|
||
Attachment #645587 -
Flags: review?(bas.schouten)
Assignee | ||
Comment 12•12 years ago
|
||
Note that the additional fixes here are only needed because of bug 772726. I decided not to block relanding this on bug 772726, partly because I want to uplift the fixes here to Aurora and I don't want to land bug 772726 on Aurora.
Updated•12 years ago
|
Attachment #645587 -
Flags: review?(bas.schouten) → review+
Updated•12 years ago
|
Attachment #645581 -
Flags: review?(bas.schouten) → review+
Assignee | ||
Comment 13•12 years ago
|
||
Assignee | ||
Comment 14•12 years ago
|
||
Comment on attachment 637302 [details] [diff] [review]
fix
Review of attachment 637302 [details] [diff] [review]:
-----------------------------------------------------------------
This is a performance improvement that makes some pages *much* better. We should take it on Aurora because we have unprefixed CSS gradients there and we don't want to be stuck with super-bad performance in some cases.
Attachment #637302 -
Flags: approval-mozilla-aurora?
Assignee | ||
Comment 15•12 years ago
|
||
Comment on attachment 645581 [details] [diff] [review]
Improve precision of bounds for cairo-D2D repeating stops
Review of attachment 645581 [details] [diff] [review]:
-----------------------------------------------------------------
This is a performance improvement that makes some pages *much* better. We should take it on Aurora because we have unprefixed CSS gradients there and we don't want to be stuck with super-bad performance in some cases.
Attachment #645581 -
Flags: approval-mozilla-aurora?
Assignee | ||
Comment 16•12 years ago
|
||
Comment on attachment 645587 [details] [diff] [review]
add some fuzziness/fail for reftests
Review of attachment 645587 [details] [diff] [review]:
-----------------------------------------------------------------
This is a performance improvement that makes some pages *much* better. We should take it on Aurora because we have unprefixed CSS gradients there and we don't want to be stuck with super-bad performance in some cases.
Attachment #645587 -
Flags: approval-mozilla-aurora?
Comment 17•12 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/ee21073be123
https://hg.mozilla.org/mozilla-central/rev/874a4984caf2
https://hg.mozilla.org/mozilla-central/rev/5e637d1f8ec6
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla17
Comment 18•12 years ago
|
||
Comment on attachment 637302 [details] [diff] [review]
fix
[Triage Comment]
Given where we are in the cycle, approving for Aurora 16 in support of new unprefixed CSS changes. We can always back out if this causes new regressions.
Attachment #637302 -
Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
Updated•12 years ago
|
Attachment #645581 -
Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
Updated•12 years ago
|
Attachment #645587 -
Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
Comment 19•12 years ago
|
||
The bug still appears on Nightly 17.0a1 (2012-07-28). Tested on Win7 64-bit.
Assignee | ||
Comment 20•12 years ago
|
||
On this page? http://estelle.github.com/mobileperf/#slide14
Comment 21•12 years ago
|
||
Did the patches land on Aurora?
Assignee | ||
Comment 22•12 years ago
|
||
Not yet. I'm waiting for Aurora approval for the regression fix in bug 779399.
Assignee | ||
Comment 23•12 years ago
|
||
https://hg.mozilla.org/releases/mozilla-aurora/rev/5e4a0ba8918d
https://hg.mozilla.org/releases/mozilla-aurora/rev/68bc6eeb7b14
https://hg.mozilla.org/releases/mozilla-aurora/rev/d25d95292cad
status-firefox16:
--- → fixed
Comment 24•12 years ago
|
||
It still has not been fixed on Nightly 17.0a1 (2012-08-20).
Assignee | ||
Comment 25•12 years ago
|
||
On which page do you still see the bug? http://estelle.github.com/mobileperf/#slide14?
Comment 26•12 years ago
|
||
@Robert, http://estelle.github.com/mobileperf/#slide14 `-moz-linear-gradient` seems rendering fine, but http://laukstein.com `repeating-linear-gradient` still is unusable slow.
Assignee | ||
Comment 27•12 years ago
|
||
I think that's a completely different problem. Please file it as a separate bug.
Assignee | ||
Comment 28•12 years ago
|
||
(And when you do, please specify your platform and about:support data.)
Comment 29•12 years ago
|
||
@Robert, `repeating-linear-gradient` and `background-size` bug 644444 https://bugzilla.mozilla.org/show_bug.cgi?id=644444 reported on 2011/03/23, the current status: RESOLVED FIXED.
I just added comment to update status and fix the bug.
Your mentioned patch in bug 768775 unfortunately did not fix the bug 644444.
Assignee | ||
Comment 30•12 years ago
|
||
OK, thanks. I reopened bug 644444.
You need to log in
before you can comment on or make changes to this bug.
Description
•