19382421b9
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 |
||
---|---|---|
animations | ||
bench | ||
debugger | ||
dm | ||
expectations | ||
experimental | ||
forth | ||
gm | ||
gyp | ||
include | ||
platform_tools | ||
resources | ||
samplecode | ||
src | ||
tests | ||
third_party | ||
tools | ||
trybots_to_run/chrome | ||
.gitignore | ||
codereview.settings | ||
CONTRIBUTING | ||
DEPS | ||
Doxyfile | ||
gyp_skia | ||
gyp_skia.py | ||
LICENSE | ||
make.bat | ||
make.py | ||
Makefile | ||
Makefile.old | ||
OWNERS | ||
PRESUBMIT.py | ||
README | ||
README.chromium | ||
skia.gyp | ||
whitespace.txt |
Skia is a complete 2D graphic library for drawing Text, Geometries, and Images. See full details, and build instructions, at http://code.google.com/p/skia/wiki/DocRoot