summaryrefslogtreecommitdiff
path: root/absl/synchronization/internal/create_thread_identity.cc
diff options
context:
space:
mode:
authorGravatar Benjamin Barenblat <bbaren@google.com>2020-09-25 17:10:06 -0400
committerGravatar Benjamin Barenblat <bbaren@google.com>2020-09-25 17:10:06 -0400
commit4e1c98fe594d99494ce26e94a77f0358705f227c (patch)
treea07e9daefa3b5acf716ce89fa1a1c9b500fde795 /absl/synchronization/internal/create_thread_identity.cc
parent7a1e14d0d29736ba9c2884d0ce81fc0af92f6ab3 (diff)
parentb56cbdd23834a65682c0b46f367f8679e83bc894 (diff)
Merge new upstream LTS 20200923
Diffstat (limited to 'absl/synchronization/internal/create_thread_identity.cc')
-rw-r--r--absl/synchronization/internal/create_thread_identity.cc6
1 files changed, 3 insertions, 3 deletions
diff --git a/absl/synchronization/internal/create_thread_identity.cc b/absl/synchronization/internal/create_thread_identity.cc
index fa0070a9..53a71b34 100644
--- a/absl/synchronization/internal/create_thread_identity.cc
+++ b/absl/synchronization/internal/create_thread_identity.cc
@@ -32,9 +32,9 @@ namespace synchronization_internal {
// ThreadIdentity storage is persistent, we maintain a free-list of previously
// released ThreadIdentity objects.
-static base_internal::SpinLock freelist_lock(
- base_internal::kLinkerInitialized);
-static base_internal::ThreadIdentity* thread_identity_freelist;
+ABSL_CONST_INIT static base_internal::SpinLock freelist_lock(
+ absl::kConstInit, base_internal::SCHEDULE_KERNEL_ONLY);
+ABSL_CONST_INIT static base_internal::ThreadIdentity* thread_identity_freelist;
// A per-thread destructor for reclaiming associated ThreadIdentity objects.
// Since we must preserve their storage we cache them for re-use.