summaryrefslogtreecommitdiff
path: root/lib/msan
diff options
context:
space:
mode:
authorAlex Shlyapnikov <alekseys@google.com>2018-06-14 18:30:51 +0000
committerAlex Shlyapnikov <alekseys@google.com>2018-06-14 18:30:51 +0000
commit8443df81847c2cb5096a137b3780c4d99ccb09a5 (patch)
tree4c292681484045fbba9d16c2d7314d953cac0b7f /lib/msan
parent4e34f2eb5a5aeac2f974ed89261e6a0508506f6e (diff)
[MSan] Linker-initialize static fallback_mutex in msan_allocator.cc
Summary: static fallback_mutex in msan_allocator.cc does not need the ctor call and can be linker initialized. Issue: https://github.com/google/sanitizers/issues/194 Reviewers: morehouse, eugenis Subscribers: delcypher, #sanitizers, llvm-commits Differential Revision: https://reviews.llvm.org/D48145 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@334749 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/msan')
-rw-r--r--lib/msan/msan_allocator.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/msan/msan_allocator.cc b/lib/msan/msan_allocator.cc
index 3d03ca42c..36f0497a9 100644
--- a/lib/msan/msan_allocator.cc
+++ b/lib/msan/msan_allocator.cc
@@ -120,7 +120,7 @@ typedef CombinedAllocator<PrimaryAllocator, AllocatorCache,
static Allocator allocator;
static AllocatorCache fallback_allocator_cache;
-static SpinMutex fallback_mutex;
+static StaticSpinMutex fallback_mutex;
void MsanAllocatorInit() {
SetAllocatorMayReturnNull(common_flags()->allocator_may_return_null);