New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 649562 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
Last visit > 30 days ago
Closed: May 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Windows
Pri: 1
Type: Bug



Sign in to add a comment

New path key computation logic causes 70% regression in Animometer Suits

Project Member Reported by ericrk@chromium.org, Sep 23 2016

Issue description

Did some benchmarking today and it appears that the recent change to how keys for short paths are computed (https://codereview.chromium.org/2357643002) caused a significant (75%) regression in the Animometer Suits benchmark.

Seems like we may have enough paths in play that the computations here are making a meaningful impact on performance.

The benchmark can be run here: https://rawgit.com/WebKit/webkit/master/PerformanceTests/Animometer/developer.html?test-interval=15&display=minimal&tiles=big&controller=ramp&frame-rate=50&kalman-process-error=1&kalman-measurement-error=4&time-measurement=performance&suite-name=Animometer&test-name=Suits&complexity=255
 

Comment 1 by bsalo...@google.com, Sep 23 2016

Owner: bsalomon@chromium.org
Status: Assigned (was: Available)

Comment 2 by bsalo...@google.com, Sep 23 2016

It looks like somehow we are getting more cache misses and therefore recomputing distance fields.

Comment 3 by bsalo...@google.com, Sep 23 2016

The problem is that this now makes us compute DFs for clip paths. Because the clip paths are transformed into device space (and the transformation animates) they are never reused.

The transformed paths are marked as "volatile". If I make the data-based key computation only fire for paths that are not explicitly marked volatile then all (or at least the vast majority) of perf is restored. I'll get that change together.

For some time we've wanted to store the clip paths in their original coordinate system. Looks like it might be time to start that work. This would allow us to improve clip path performance.

Here are numbers from my linux machine for 3 modes, 5 runs each:

TOT: 20, 35, 35, 18, 23
No data key (change reverted): 405, 331, 405, 400, 377
Skip data key for volatile: 386, 367, 358, 340, 382

It's hard to say if all the perf has been restored given the amount of variability in measurements.

Comment 4 by bsalo...@google.com, Sep 23 2016

Cc: fmalita@chromium.org
Florin, It seems like in the Suits test some of the clip-path/draw-rects get transformed into draw-path and some don't. I was wondering if you had any insight into what the difference might be.
Project Member

Comment 5 by bugdroid1@chromium.org, Sep 23 2016

The following revision refers to this bug:
  https://skia.googlesource.com/skia.git/+/aa840647fc7f057715bce62489b96c4299385135

commit aa840647fc7f057715bce62489b96c4299385135
Author: bsalomon <bsalomon@google.com>
Date: Fri Sep 23 19:09:16 2016

Don't compute path keys for volatile paths in GrShape.

Otherwise, we will compute cache keys for internally transformed paths that don't repeat (e.g. clip paths transformed into device space with a changing view matrix).

BUG= chromium:649562 
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2369513002

Review-Url: https://codereview.chromium.org/2369513002

[modify] https://crrev.com/aa840647fc7f057715bce62489b96c4299385135/src/gpu/GrShape.cpp
[modify] https://crrev.com/aa840647fc7f057715bce62489b96c4299385135/tests/GpuDrawPathTest.cpp
[modify] https://crrev.com/aa840647fc7f057715bce62489b96c4299385135/tests/GrShapeTest.cpp

Project Member

Comment 6 by bugdroid1@chromium.org, Sep 23 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/6a455fc9785a0ba64c79d4a505fedaad3c4cc2df

commit 6a455fc9785a0ba64c79d4a505fedaad3c4cc2df
Author: skia-deps-roller <skia-deps-roller@chromium.org>
Date: Fri Sep 23 20:09:41 2016

Roll src/third_party/skia/ cc0937273..aa840647f (4 commits).

https://chromium.googlesource.com/skia.git/+log/cc0937273030..aa840647fc7f

$ git log cc0937273..aa840647f --date=short --no-merges --format='%ad %ae %s'
2016-09-23 bsalomon Don't compute path keys for volatile paths in GrShape.
2016-09-23 csmartdalton Add Pixel C knobs to skpbench
2016-09-23 jvanverth Some Vulkan memory fixes and cleanup
2016-09-23 reed change SkXfermodeImageFilter to carry no impl information

BUG= 649562 

CQ_INCLUDE_TRYBOTS=master.tryserver.blink:linux_precise_blink_rel
TBR=borenet@google.com

Review-Url: https://codereview.chromium.org/2367933002
Cr-Commit-Position: refs/heads/master@{#420710}

[modify] https://crrev.com/6a455fc9785a0ba64c79d4a505fedaad3c4cc2df/DEPS

Status: Fixed (was: Assigned)

Sign in to add a comment