aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGravatar mtklein <mtklein@chromium.org>2014-12-15 13:38:07 -0800
committerGravatar Commit bot <commit-bot@chromium.org>2014-12-15 13:38:07 -0800
commit0faaac64187a1cb811b03d48be3e6d2e24a799c1 (patch)
tree5cd3d091cc49ed89bfe85eb4d5973b395fb64c6b
parent8893e5f030cb2f6c3bdf698c1767a244ae098a5c (diff)
Look at DYNAMIC_ANNOTATIONS_ENABLED now.
Defining SK_DYNAMIC_ANNOTATIONS_ENABLED as 1 whenever DYNAMIC_ANNOTATIONS_ENABLED was 1 seems to be working fine for Chrome. Should be we can just use DYNAMIC_ANNOTATIONS_ENABLED. BUG=skia: Review URL: https://codereview.chromium.org/810513002
-rw-r--r--gyp/common_conditions.gypi2
-rw-r--r--include/core/SkDynamicAnnotations.h6
2 files changed, 4 insertions, 4 deletions
diff --git a/gyp/common_conditions.gypi b/gyp/common_conditions.gypi
index 059806f5e3..32335f9416 100644
--- a/gyp/common_conditions.gypi
+++ b/gyp/common_conditions.gypi
@@ -459,7 +459,7 @@
],
'conditions' : [
[ 'skia_sanitizer == "thread"', {
- 'defines': [ 'SK_DYNAMIC_ANNOTATIONS_ENABLED=1' ],
+ 'defines': [ 'DYNAMIC_ANNOTATIONS_ENABLED=1' ],
}],
[ 'skia_sanitizer == "undefined"', {
'cflags_cc!': ['-fno-rtti'],
diff --git a/include/core/SkDynamicAnnotations.h b/include/core/SkDynamicAnnotations.h
index af8bdb675f..e7710307f5 100644
--- a/include/core/SkDynamicAnnotations.h
+++ b/include/core/SkDynamicAnnotations.h
@@ -8,14 +8,14 @@
#ifndef SkDynamicAnnotations_DEFINED
#define SkDynamicAnnotations_DEFINED
-// Make sure we see anything set via SkUserConfig.h (e.g. SK_DYNAMIC_ANNOTATIONS_ENABLED).
+// Make sure we see anything set via SkUserConfig.h (e.g. DYNAMIC_ANNOTATIONS_ENABLED).
#include "SkTypes.h"
// This file contains macros used to send out-of-band signals to dynamic instrumentation systems,
// namely thread sanitizer. This is a cut-down version of the full dynamic_annotations library with
// only the features used by Skia.
-#if SK_DYNAMIC_ANNOTATIONS_ENABLED
+#if DYNAMIC_ANNOTATIONS_ENABLED
extern "C" {
// TSAN provides these hooks.
@@ -58,7 +58,7 @@ void SK_ANNOTATE_BENIGN_RACE(T* ptr) {
AnnotateBenignRaceSized(__FILE__, __LINE__, ptr, sizeof(*ptr), "SK_ANNOTATE_BENIGN_RACE");
}
-#else // !SK_DYNAMIC_ANNOTATIONS_ENABLED
+#else // !DYNAMIC_ANNOTATIONS_ENABLED
#define SK_ANNOTATE_UNPROTECTED_READ(x) (x)
#define SK_ANNOTATE_UNPROTECTED_WRITE(ptr, val) *(ptr) = (val)