Go to file
Nigel Tao 39da10b556 Optimize SkWuffsCodec pixbuf zero-initialization
Pushing the zero-initialization into the sk_malloc_etc call can be more
efficient than a two-step malloc-and-then-memset, e.g. if the memory
allocator gives us something from an already-known-zeroed region.

Some microbenchmark numbers (milliseconds per decode) from running
Chromium's image_decode_bench program on a few GIF files:

Before  After   Ratio   Filename        Width x Height = Pixels
 0.109   0.107  1.02    hat.gif           90  x  112   =   10080
 7.062   6.879  1.03    harvesters.gif  1165  x  859   = 1000735
33.342  30.544  1.09    droids.gif      2560  x 1920   = 4915200

Ratio > 1.00 means a performance improvement.

image_decode_bench comes from:
https://cs.chromium.org/chromium/src/third_party/blink/renderer/platform/testing/image_decode_bench.cc

hat.gif and harvesters.gif come from:
https://github.com/google/wuffs/tree/master/test/data

droids.gif comes from:
https://cs.chromium.org/chromium/src/third_party/blink/perf_tests/image_decoder/resources/

These are x86_64 Broadwell numbers. I don't have ARM numbers readily
available, but nothing about this commit should be arch-specific.

Bug: skia:8235
Change-Id: Icf45b7ac5b7194eaab455628e44d4aedf30ddbfe
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/254836
Commit-Queue: Leon Scroggins <scroggo@google.com>
Reviewed-by: Leon Scroggins <scroggo@google.com>
2019-11-18 20:44:20 +00:00
animations
bench Expose the owning surface to a canvas? 2019-11-15 21:48:32 +00:00
bin [infra] Fix bin/try 2019-11-15 19:44:04 +00:00
build/fuchsia Reformat gn files 2019-11-18 16:39:28 +00:00
build_overrides Update Dawn backend to ToT. This is about 3 months of changes. 2019-10-15 22:26:38 +00:00
dm remove unused (by clients) SkMultiPictureDraw 2019-11-15 18:18:36 +00:00
docker Fix usage of depot_tools in containers. 2019-10-14 19:38:40 +00:00
docs/examples docs/fiddle: add "incomplete" fiddle. 2019-10-11 18:22:34 +00:00
example Revert "add guard to switch to SkPathTypes" 2019-09-14 19:13:44 +00:00
experimental Reland "Minimal iOS app: Perform present subsequent to flush" 2019-10-14 18:32:37 +00:00
fuzz [fuzzing] Fix skdescriptor deserialize compile 2019-10-23 11:54:14 +00:00
gm Add SampleLocationsTestOp::onPrePrepare 2019-11-18 17:50:19 +00:00
gn Reformat gn files 2019-11-18 16:39:28 +00:00
include Rename opPODAllocator to recordTimeAllocator 2019-11-18 16:12:38 +00:00
infra Run nanobench on droids.gif 2019-11-18 18:47:19 +00:00
modules [canvaskit] Roll to 0.9.0 2019-11-18 12:23:34 +00:00
platform_tools android_gdbserver: Don't fail when trying to locate nonexistent files 2019-09-16 16:28:33 +00:00
resources [skottie] One-node camera support 2019-11-14 18:45:18 +00:00
samplecode restructure EdgeClipper to accommodate other callers (e.g. half-plane) 2019-11-18 18:22:19 +00:00
site [infra] Update docs with respect to Go modules. 2019-11-18 18:04:19 +00:00
specs [img-decode] Start on proposed new spec 2019-05-06 17:39:19 +00:00
src Optimize SkWuffsCodec pixbuf zero-initialization 2019-11-18 20:44:20 +00:00
tests SKQP Build for Fuchsia SDK 2019-11-18 12:34:28 +00:00
third_party SKQP Build for Fuchsia SDK 2019-11-18 12:34:28 +00:00
tools SKQP Build for Fuchsia SDK 2019-11-18 12:34:28 +00:00
.clang-format restore .clang-format 2019-03-21 15:52:32 +00:00
.clang-tidy add google-build-namespaces to clang-tidy checks 2018-12-12 16:33:59 +00:00
.gitignore clean up some .gitignores 2019-05-15 19:55:45 +00:00
.gn
AUTHORS Issue- >Skia tiled bitmap rendering is too slow when tildmodeX is not same as tileModeY. 2019-11-14 20:52:18 +00:00
BUILD.gn Reformat gn files 2019-11-18 16:39:28 +00:00
codereview.settings
CONTRIBUTING
CQ_COMMITTERS
DEPS Roll ../src 6961018759e7..c30db006f1d6 (480 commits) 2019-11-18 12:53:42 +00:00
go.mod Update Go deps 2019-10-24 05:26:54 +00:00
go.sum Blacklist bulkrect benchmarks on chorizo 2019-10-28 22:04:15 +00:00
LICENSE
OWNERS
PRESUBMIT.py Use urllib_request instead of urllib2 in PRESUBMIT. 2019-10-22 20:30:56 +00:00
public.bzl Fixing no icu situation 2019-11-08 18:59:03 +00:00
README
README.chromium
RELEASE_NOTES.txt Clamp RGB outputs of GrYUVtoRGBEffect. 2019-11-11 20:04:15 +00:00
whitespace.txt Whitespace test 2019-05-18 13:05:29 +00:00

Skia is a complete 2D graphic library for drawing Text, Geometries, and Images.

See full details, and build instructions, at https://skia.org.