about summary refs log tree commit diff
path: root/absl/synchronization/mutex_benchmark.cc
diff options
context:
space:
mode:
Diffstat (limited to 'absl/synchronization/mutex_benchmark.cc')
-rw-r--r--absl/synchronization/mutex_benchmark.cc8
1 files changed, 4 insertions, 4 deletions
diff --git a/absl/synchronization/mutex_benchmark.cc b/absl/synchronization/mutex_benchmark.cc
index 30a523556c3d..1e019e001ae4 100644
--- a/absl/synchronization/mutex_benchmark.cc
+++ b/absl/synchronization/mutex_benchmark.cc
@@ -74,11 +74,11 @@ void BM_ConditionWaiters(benchmark::State& state) {
   mu.Unlock();
 }
 
-#ifdef THREAD_SANITIZER
-// ThreadSanitizer can't handle 8192 threads.
-constexpr int kMaxConditionWaiters = 2048;
-#else
+// Some configurations have higher thread limits than others.
+#if defined(__linux__) && !defined(THREAD_SANITIZER)
 constexpr int kMaxConditionWaiters = 8192;
+#else
+constexpr int kMaxConditionWaiters = 1024;
 #endif
 BENCHMARK(BM_ConditionWaiters)->RangePair(0, 2, 1, kMaxConditionWaiters);