From 930ccf0191b4a33332d924522e5676fff583f083 Mon Sep 17 00:00:00 2001 From: Vitaly Buka Date: Sun, 14 Nov 2021 22:37:52 -0800 Subject: [PATCH] [NFC][sanitizer] Rename persistent_allocator to stack_store --- compiler-rt/lib/sanitizer_common/CMakeLists.txt | 2 +- .../lib/sanitizer_common/sanitizer_chained_origin_depot.cpp | 1 - ...anitizer_persistent_allocator.h => sanitizer_stack_store.h} | 10 +++++----- compiler-rt/lib/sanitizer_common/sanitizer_stackdepot.cpp | 2 +- .../gn/secondary/compiler-rt/lib/sanitizer_common/BUILD.gn | 2 +- 5 files changed, 8 insertions(+), 9 deletions(-) rename compiler-rt/lib/sanitizer_common/{sanitizer_persistent_allocator.h => sanitizer_stack_store.h} (95%) diff --git a/compiler-rt/lib/sanitizer_common/CMakeLists.txt b/compiler-rt/lib/sanitizer_common/CMakeLists.txt index 4c7ca62..0c14738 100644 --- a/compiler-rt/lib/sanitizer_common/CMakeLists.txt +++ b/compiler-rt/lib/sanitizer_common/CMakeLists.txt @@ -156,7 +156,6 @@ set(SANITIZER_IMPL_HEADERS sanitizer_mac.h sanitizer_malloc_mac.inc sanitizer_mutex.h - sanitizer_persistent_allocator.h sanitizer_placement_new.h sanitizer_platform.h sanitizer_platform_interceptors.h @@ -170,6 +169,7 @@ set(SANITIZER_IMPL_HEADERS sanitizer_report_decorator.h sanitizer_ring_buffer.h sanitizer_signal_interceptors.inc + sanitizer_stack_store.h sanitizer_stackdepot.h sanitizer_stackdepotbase.h sanitizer_stacktrace.h diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_chained_origin_depot.cpp b/compiler-rt/lib/sanitizer_common/sanitizer_chained_origin_depot.cpp index 626777d..472b83d 100644 --- a/compiler-rt/lib/sanitizer_common/sanitizer_chained_origin_depot.cpp +++ b/compiler-rt/lib/sanitizer_common/sanitizer_chained_origin_depot.cpp @@ -11,7 +11,6 @@ #include "sanitizer_chained_origin_depot.h" -#include "sanitizer_persistent_allocator.h" #include "sanitizer_stackdepotbase.h" namespace __sanitizer { diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_persistent_allocator.h b/compiler-rt/lib/sanitizer_common/sanitizer_stack_store.h similarity index 95% rename from compiler-rt/lib/sanitizer_common/sanitizer_persistent_allocator.h rename to compiler-rt/lib/sanitizer_common/sanitizer_stack_store.h index e18b003..b91cfb7 100644 --- a/compiler-rt/lib/sanitizer_common/sanitizer_persistent_allocator.h +++ b/compiler-rt/lib/sanitizer_common/sanitizer_stack_store.h @@ -1,4 +1,4 @@ -//===-- sanitizer_persistent_allocator.h ------------------------*- C++ -*-===// +//===-- sanitizer_stack_store.h ---------------------------------*- C++ -*-===// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. @@ -13,10 +13,10 @@ #ifndef SANITIZER_PERSISTENT_ALLOCATOR_H #define SANITIZER_PERSISTENT_ALLOCATOR_H -#include "sanitizer_internal_defs.h" -#include "sanitizer_mutex.h" #include "sanitizer_atomic.h" #include "sanitizer_common.h" +#include "sanitizer_internal_defs.h" +#include "sanitizer_mutex.h" namespace __sanitizer { @@ -105,6 +105,6 @@ void PersistentAllocator::TestOnlyUnmap() { internal_memset(this, 0, sizeof(*this)); } -} // namespace __sanitizer +} // namespace __sanitizer -#endif // SANITIZER_PERSISTENT_ALLOCATOR_H +#endif // SANITIZER_PERSISTENT_ALLOCATOR_H diff --git a/compiler-rt/lib/sanitizer_common/sanitizer_stackdepot.cpp b/compiler-rt/lib/sanitizer_common/sanitizer_stackdepot.cpp index 0285545..7f9220d 100644 --- a/compiler-rt/lib/sanitizer_common/sanitizer_stackdepot.cpp +++ b/compiler-rt/lib/sanitizer_common/sanitizer_stackdepot.cpp @@ -14,7 +14,7 @@ #include "sanitizer_common.h" #include "sanitizer_hash.h" -#include "sanitizer_persistent_allocator.h" +#include "sanitizer_stack_store.h" #include "sanitizer_stackdepotbase.h" namespace __sanitizer { diff --git a/llvm/utils/gn/secondary/compiler-rt/lib/sanitizer_common/BUILD.gn b/llvm/utils/gn/secondary/compiler-rt/lib/sanitizer_common/BUILD.gn index 6d1b481..c4ab704 100644 --- a/llvm/utils/gn/secondary/compiler-rt/lib/sanitizer_common/BUILD.gn +++ b/llvm/utils/gn/secondary/compiler-rt/lib/sanitizer_common/BUILD.gn @@ -87,7 +87,6 @@ source_set("sources") { "sanitizer_mutex.cpp", "sanitizer_mutex.h", "sanitizer_netbsd.cpp", - "sanitizer_persistent_allocator.h", "sanitizer_placement_new.h", "sanitizer_platform.h", "sanitizer_platform_interceptors.h", @@ -115,6 +114,7 @@ source_set("sources") { "sanitizer_report_decorator.h", "sanitizer_ring_buffer.h", "sanitizer_solaris.cpp", + "sanitizer_stack_store.h", "sanitizer_stackdepot.cpp", "sanitizer_stackdepot.h", "sanitizer_stackdepotbase.h", -- 2.7.4