History log of /external/skia/bench/WriterBench.cpp
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
f168b86d7fafc5c20c87bebc6fd393cb17e120ca 19-Jun-2014 tfarina <tfarina@chromium.org> Remove Sk prefix from some bench classes.

This idea came while commenting on
https://codereview.chromium.org/343583005/

Since SkBenchmark, SkBenchLogger and SkGMBench are not part of the Skia library,
they should not have the Sk prefix.

BUG=None
TEST=make all
R=mtklein@google.com

Author: tfarina@chromium.org

Review URL: https://codereview.chromium.org/347823004
/external/skia/bench/WriterBench.cpp
19382421b916aab00be7265815ba4e2690adf2c9 14-Jan-2014 commit-bot@chromium.org <commit-bot@chromium.org@2bbb7eff-a529-9590-31e7-b0007b416f81> Convert SkWriter32 to use an SkTDArray for its internal storage.

This reduces the allocation overhead of a null picture (create, beginRecording(), endRecording) from about 18K to about 1.9K. (There's still lots more to prune.)

SkPictureFlat can exploit the fact that Writer32 is contiguous simplify its memory management. The Writer32 itself becomes the scratch buffer.

Remove lots and lots of arbitrary magic numbers that were size guesses and minimum allocation sizes. Keep your eyes open for the big obvious DUH why we save 16K per picture! (Spoiler alert. It's because that first save we issue in beginRecording() forces the old SkWriter32 to allocate 16K.)

Tests passing, DM passing.

bench --match writer: ~20% faster
null bench_record: ~30% faster
bench_record on buildbot .skps: ~3-6% slower, ranging 25% faster to 20% slower
bench_pictures on buildbot .skps: ~1-2% faster, ranging 13% faster to 28% slower

BUG=skia:1850
R=reed@google.com

Author: mtklein@google.com

Review URL: https://codereview.chromium.org/137433003

git-svn-id: http://skia.googlecode.com/svn/trunk@13073 2bbb7eff-a529-9590-31e7-b0007b416f81
/external/skia/bench/WriterBench.cpp
3361471a3504ecd0351ff70f4c42d8d6fee963d4 03-Dec-2013 commit-bot@chromium.org <commit-bot@chromium.org@2bbb7eff-a529-9590-31e7-b0007b416f81> Simplify benchmark internal API.

I'm not quite sure why I wrote such a convoluted API with setLoops()/getLoops().
This replaces it with a loops argument passed to onDraw().

This CL is largely mechanical translation from the old API to the new one.
MathBench used this->getLoops() outside onDraw(), which seems incorrect. I
fixed it.

BUG=
R=djsollen@google.com

Author: mtklein@google.com

Review URL: https://codereview.chromium.org/99893003

git-svn-id: http://skia.googlecode.com/svn/trunk@12466 2bbb7eff-a529-9590-31e7-b0007b416f81
/external/skia/bench/WriterBench.cpp
644629c1c7913a43ced172b98d56e0f471bc348b 21-Nov-2013 commit-bot@chromium.org <commit-bot@chromium.org@2bbb7eff-a529-9590-31e7-b0007b416f81> Implement a benchmark for GrResourceCache

Adds "grresourcecache_add" and "grresourcecache_find" bench tests to test
GrResourceCache::add and GrResourceCache::find. The tests work only
with GPU backends, since GrResourceCache needs an GrGpu.

Modifies bench tests to override SkBenchmark::isSuitableFor(Backend)
function that specifies what kind of backend the test is inteded
for. This replaces the previous "fIsRendering" flag that would
indicate test that did no rendering.

Adds SkCanvas::getGrContext() call to get the GrContext that the
canvas ends up drawing to. The member function solves a common
use-case that is also used in the benchmark added here.

R=mtklein@google.com, bsalomon@google.com

Author: kkinnunen@nvidia.com

Review URL: https://codereview.chromium.org/73643005

git-svn-id: http://skia.googlecode.com/svn/trunk@12334 2bbb7eff-a529-9590-31e7-b0007b416f81
/external/skia/bench/WriterBench.cpp
410e6e80f00a6c660675c80904807a041c7b7d2a 13-Sep-2013 mtklein@google.com <mtklein@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> Refactoring: get rid of the SkBenchmark void* parameter.

While I was doing massive sed-ing, I also converted every bench to use DEF_BENCH instead of registering the ugly manual way.

BUG=
R=scroggo@google.com

Review URL: https://codereview.chromium.org/23876006

git-svn-id: http://skia.googlecode.com/svn/trunk@11263 2bbb7eff-a529-9590-31e7-b0007b416f81
/external/skia/bench/WriterBench.cpp
c289743864e2ab926a95e617a5cd1d29b26d1825 10-Sep-2013 mtklein@google.com <mtklein@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> Major bench refactoring.
- Use FLAGS_.
- Remove outer repeat loop.
- Tune inner loop automatically.

BUG=skia:1590
R=epoger@google.com, scroggo@google.com

Review URL: https://codereview.chromium.org/23478013

git-svn-id: http://skia.googlecode.com/svn/trunk@11187 2bbb7eff-a529-9590-31e7-b0007b416f81
/external/skia/bench/WriterBench.cpp
77472f06f88b85e85fb690584c85d0a42e74b685 05-Mar-2013 sugoi@google.com <sugoi@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> Bench : Unused parameters cleanup

I removed unused parameters in bench wherever it was trivial to do so.
Review URL: https://codereview.appspot.com/7411046

git-svn-id: http://skia.googlecode.com/svn/trunk@7988 2bbb7eff-a529-9590-31e7-b0007b416f81
/external/skia/bench/WriterBench.cpp
433ce5e6869d5937e31ff5f305be54092b37f2e4 17-Sep-2012 robertphillips@google.com <robertphillips@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> Made more benchs non-rendering

http://codereview.appspot.com/6498132/



git-svn-id: http://skia.googlecode.com/svn/trunk@5562 2bbb7eff-a529-9590-31e7-b0007b416f81
/external/skia/bench/WriterBench.cpp
dd3948899725041bf52e3a4eea922f9961ee0a9b 24-Jul-2012 scroggo@google.com <scroggo@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> Avoid a loop in writeString and writePad by zeroing padding first.

Also add a benchmark to time the new improved writeString. Before
my change the bench took ~1.23ms and afterwards it takes ~.95ms.

Add some testing to ensure that writePad works properly.

TEST=Writer32Test, WriterBench

Review URL: https://codereview.appspot.com/6438045

git-svn-id: http://skia.googlecode.com/svn/trunk@4742 2bbb7eff-a529-9590-31e7-b0007b416f81
/external/skia/bench/WriterBench.cpp