summaryrefslogtreecommitdiff
path: root/absl/synchronization/internal
diff options
context:
space:
mode:
Diffstat (limited to 'absl/synchronization/internal')
-rw-r--r--absl/synchronization/internal/mutex_nonprod.cc3
-rw-r--r--absl/synchronization/internal/per_thread_sem_test.cc1
-rw-r--r--absl/synchronization/internal/waiter.h2
3 files changed, 4 insertions, 2 deletions
diff --git a/absl/synchronization/internal/mutex_nonprod.cc b/absl/synchronization/internal/mutex_nonprod.cc
index 1732f836..334c3bc0 100644
--- a/absl/synchronization/internal/mutex_nonprod.cc
+++ b/absl/synchronization/internal/mutex_nonprod.cc
@@ -27,6 +27,7 @@
#include <algorithm>
+#include "absl/base/config.h"
#include "absl/base/internal/raw_logging.h"
#include "absl/time/time.h"
@@ -278,7 +279,7 @@ bool CondVar::WaitWithTimeout(Mutex* mu, absl::Duration timeout) {
void CondVar::EnableDebugLog(const char*) {}
-#ifdef THREAD_SANITIZER
+#ifdef ABSL_HAVE_THREAD_SANITIZER
extern "C" void __tsan_read1(void *addr);
#else
#define __tsan_read1(addr) // do nothing if TSan not enabled
diff --git a/absl/synchronization/internal/per_thread_sem_test.cc b/absl/synchronization/internal/per_thread_sem_test.cc
index b5a2f6d4..8cf59e64 100644
--- a/absl/synchronization/internal/per_thread_sem_test.cc
+++ b/absl/synchronization/internal/per_thread_sem_test.cc
@@ -23,6 +23,7 @@
#include <thread> // NOLINT(build/c++11)
#include "gtest/gtest.h"
+#include "absl/base/config.h"
#include "absl/base/internal/cycleclock.h"
#include "absl/base/internal/thread_identity.h"
#include "absl/strings/str_cat.h"
diff --git a/absl/synchronization/internal/waiter.h b/absl/synchronization/internal/waiter.h
index ae83907b..887f9b1b 100644
--- a/absl/synchronization/internal/waiter.h
+++ b/absl/synchronization/internal/waiter.h
@@ -100,7 +100,7 @@ class Waiter {
}
// How many periods to remain idle before releasing resources
-#ifndef THREAD_SANITIZER
+#ifndef ABSL_HAVE_THREAD_SANITIZER
static constexpr int kIdlePeriods = 60;
#else
// Memory consumption under ThreadSanitizer is a serious concern,