aboutsummaryrefslogtreecommitdiffhomepage
path: root/include
diff options
context:
space:
mode:
authorGravatar mtklein <mtklein@chromium.org>2016-07-27 08:40:45 -0700
committerGravatar Commit bot <commit-bot@chromium.org>2016-07-27 08:40:45 -0700
commit570c868b38c7bd56bb1bc3b73d94cdd7069a04bd (patch)
tree0de2584d91ad0e6fdeb8ad65b0d35b954c72c698 /include
parent735109c24892a95290974c9665527b57b01e5440 (diff)
Clean up some unused atomic routines.
AtomicTest was the only use of sk_atomic_add(). AtomicInc64 bench was the only use of sk_atomic_inc(int64_t*). BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2183473005 CQ_INCLUDE_TRYBOTS=master.client.skia:Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-TSAN-Trybot,Test-Ubuntu-GCC-Golo-GPU-GT610-x86_64-Release-TSAN-Trybot Review-Url: https://codereview.chromium.org/2183473005
Diffstat (limited to 'include')
-rw-r--r--include/private/SkAtomics.h7
1 files changed, 2 insertions, 5 deletions
diff --git a/include/private/SkAtomics.h b/include/private/SkAtomics.h
index bfe93d8bac..56272e25e6 100644
--- a/include/private/SkAtomics.h
+++ b/include/private/SkAtomics.h
@@ -153,10 +153,7 @@ T sk_atomic_exchange(T* ptr, T val, sk_memory_order mo) {
// We use the default sequentially-consistent memory order to make things simple
// and to match the practical reality of our old _sync and _win implementations.
-inline int32_t sk_atomic_inc(int32_t* ptr) { return sk_atomic_fetch_add(ptr, +1); }
-inline int32_t sk_atomic_dec(int32_t* ptr) { return sk_atomic_fetch_add(ptr, -1); }
-inline int32_t sk_atomic_add(int32_t* ptr, int32_t v) { return sk_atomic_fetch_add(ptr, v); }
-
-inline int64_t sk_atomic_inc(int64_t* ptr) { return sk_atomic_fetch_add<int64_t>(ptr, +1); }
+inline int32_t sk_atomic_inc(int32_t* ptr) { return sk_atomic_fetch_add(ptr, +1); }
+inline int32_t sk_atomic_dec(int32_t* ptr) { return sk_atomic_fetch_add(ptr, -1); }
#endif//SkAtomics_DEFINED