diff options
author | Robin Burchell <robin.burchell@crimson.no> | 2017-04-25 00:03:22 +0200 |
---|---|---|
committer | Robin Burchell <robin.burchell@crimson.no> | 2017-04-28 17:46:49 +0000 |
commit | 9709d04ba7787c853a1ddbeed0347eab27c0924f (patch) | |
tree | 9c2e796acad520e7e4db47a5113439b7f1b53e26 /src/qml/qml/qqmlplatform.cpp | |
parent | a28b6107f82fefe2b4e0a5f553b6dae5e3186168 (diff) |
QQuickRectangle: Optimize setGradient
Similarly to the QQuickPen optimization, we can avoid a signal
connection by using the parent pointer of the QQuickGradient.
This improves qmlbench's delegates_rect_gradient.qml by ~6% for me:
Before: 300.6 frames; using samples; MedianAll=301; StdDev=4.61519, CoV=0.01535
After: 320.4 frames; using samples; MedianAll=321; StdDev=1.94936, CoV=0.00608414
Again, hopefully, the resulting lessening in allocations and improvement
in performance will help stabilize the benchmark a little on some
systems, as well as the improvement to performance and memory use.
Change-Id: Id8e0399f5a4a0ef55d7fc9b8f100af229f389ddd
Reviewed-by: Gunnar Sletta <gunnar@crimson.no>
Reviewed-by: Michael Brasser <michael.brasser@live.com>
Diffstat (limited to 'src/qml/qml/qqmlplatform.cpp')
0 files changed, 0 insertions, 0 deletions