Outline SkSpinlock::acquire().
authormtklein <mtklein@chromium.org>
Thu, 9 Jul 2015 17:51:36 +0000 (10:51 -0700)
committerCommit bot <commit-bot@chromium.org>
Thu, 9 Jul 2015 17:51:36 +0000 (10:51 -0700)
commit828877d7267bcb7c272a1df4e36a6a79894bf00d
tree3318a7c52ab29d10887412dc2e6733e5d99f506f
parentaf4edf9ccc274bef118b268145e0d1ae25072a5f
Outline SkSpinlock::acquire().

The proportion of time spent doing useful work is well over 99% in acquire(),
so outlining it doesn't hurt speed at all, and makes it much easier to pick out
on a profile.

It'd be about 50/50 work/overhead if we outlined the extremely-cheap release().
I also tried outlining some SkRefCnt methods with similar mixed results.

BUG=skia:

No public API changes.
TBR=reed@google.com

Review URL: https://codereview.chromium.org/1212253013
gyp/core.gypi
include/core/SkSpinlock.h
src/core/SkSpinlock.cpp [new file with mode: 0644]