[compiler-rt] 924032c - [NFC][hwasan] Check _GLIBCXX_RELEASE in test
Vitaly Buka via llvm-commits
llvm-commits at lists.llvm.org
Wed Feb 23 14:31:52 PST 2022
Author: Vitaly Buka
Date: 2022-02-23T14:31:47-08:00
New Revision: 924032c592658b19d9e1faeef0fea14414814f39
URL: https://github.com/llvm/llvm-project/commit/924032c592658b19d9e1faeef0fea14414814f39
DIFF: https://github.com/llvm/llvm-project/commit/924032c592658b19d9e1faeef0fea14414814f39.diff
LOG: [NFC][hwasan] Check _GLIBCXX_RELEASE in test
Differential Revision: https://reviews.llvm.org/D119161
Added:
Modified:
compiler-rt/test/hwasan/TestCases/new-test.cpp
Removed:
################################################################################
diff --git a/compiler-rt/test/hwasan/TestCases/new-test.cpp b/compiler-rt/test/hwasan/TestCases/new-test.cpp
index 7e4a4ae6557f2..d21a80d0de327 100644
--- a/compiler-rt/test/hwasan/TestCases/new-test.cpp
+++ b/compiler-rt/test/hwasan/TestCases/new-test.cpp
@@ -18,7 +18,7 @@ int main() {
assert(__sanitizer_get_allocated_size(a1) == 0);
delete[] a1;
-#ifdef __cpp_aligned_new
+#if defined(__cpp_aligned_new) && (!defined(_GLIBCXX_RELEASE) || _GLIBCXX_RELEASE >= 7)
// Aligned new/delete
constexpr auto kAlign = std::align_val_t{8};
void *a2 = ::operator new(4, kAlign);
More information about the llvm-commits
mailing list