From d70bb8d8cbe78dceb6d3ac501244874d8f1b85af Mon Sep 17 00:00:00 2001 From: Nico Weber Date: Wed, 25 Feb 2015 04:39:21 +0000 Subject: [PATCH] Revert 230419, 230425, 230432. They don't build on Windows. http://lab.llvm.org:8011/builders/sanitizer-windows/ went red for example. llvm-svn: 230461 --- compiler-rt/lib/asan/asan_suppressions.cc | 11 ----------- compiler-rt/lib/asan/asan_win.cc | 1 - .../test/asan/TestCases/Linux/asan_default_suppressions.cc | 7 ------- 3 files changed, 19 deletions(-) delete mode 100644 compiler-rt/test/asan/TestCases/Linux/asan_default_suppressions.cc diff --git a/compiler-rt/lib/asan/asan_suppressions.cc b/compiler-rt/lib/asan/asan_suppressions.cc index 6912c6a..ea40554 100644 --- a/compiler-rt/lib/asan/asan_suppressions.cc +++ b/compiler-rt/lib/asan/asan_suppressions.cc @@ -31,22 +31,11 @@ static const char *kSuppressionTypes[] = { kInterceptorName, kInterceptorViaFunction, kInterceptorViaLibrary, kODRViolation}; -#if SANITIZER_SUPPORTS_WEAK_HOOKS -extern "C" { -SANITIZER_INTERFACE_ATTRIBUTE SANITIZER_WEAK_ATTRIBUTE -const char *__asan_default_suppressions(); -} // extern "C" -#endif // SANITIZER_SUPPORTS_WEAK_HOOKS - void InitializeSuppressions() { CHECK_EQ(nullptr, suppression_ctx); suppression_ctx = new (suppression_placeholder) // NOLINT SuppressionContext(kSuppressionTypes, ARRAY_SIZE(kSuppressionTypes)); suppression_ctx->ParseFromFile(flags()->suppressions); -#if SANITIZER_SUPPORTS_WEAK_HOOKS - if (&__asan_default_suppressions) - suppression_ctx->Parse(__asan_default_suppressions()); -#endif // SANITIZER_SUPPORTS_WEAK_HOOKS } bool IsInterceptorSuppressed(const char *interceptor_name) { diff --git a/compiler-rt/lib/asan/asan_win.cc b/compiler-rt/lib/asan/asan_win.cc index 119ecd8..0ffedb2 100644 --- a/compiler-rt/lib/asan/asan_win.cc +++ b/compiler-rt/lib/asan/asan_win.cc @@ -44,7 +44,6 @@ void __asan_default_on_error() {} #pragma comment(linker, "/alternatename:___sanitizer_malloc_hook=___sanitizer_default_malloc_hook") // NOLINT #pragma comment(linker, "/alternatename:___sanitizer_free_hook=___sanitizer_default_free_hook") // NOLINT #pragma comment(linker, "/alternatename:___asan_default_options=___asan_default_default_options") // NOLINT -#pragma comment(linker, "/alternatename:___asan_default_suppressions=___asan_default_default_suppressions") // NOLINT #pragma comment(linker, "/alternatename:___asan_on_error=___asan_default_on_error") // NOLINT } // extern "C" diff --git a/compiler-rt/test/asan/TestCases/Linux/asan_default_suppressions.cc b/compiler-rt/test/asan/TestCases/Linux/asan_default_suppressions.cc deleted file mode 100644 index 5ff59c1..0000000 --- a/compiler-rt/test/asan/TestCases/Linux/asan_default_suppressions.cc +++ /dev/null @@ -1,7 +0,0 @@ -// Test that we use the suppressions from __asan_default_suppressions. -// RUN: %clangxx_asan %s -o %t && not %run %t 2>&1 | FileCheck %s -extern "C" { - const char *__asan_default_suppressions() { return "FooBar"; } -} -// CHECK: AddressSanitizer: failed to parse suppressions -int main() {} -- 2.7.4