Remove some trivial copy ctors so the classes become trivially copyable and get the...
[oota-llvm.git] / include / llvm / Support / Valgrind.h
index 0ecd33b6dd1c963095f21b771a657563b8413dfc..e14764703932bfd72f9e9a16170d0fd050e5b08b 100644 (file)
 #define LLVM_SYSTEM_VALGRIND_H
 
 #include "llvm/Support/Compiler.h"
-#include "llvm/Config/config.h"
+#include "llvm/Config/llvm-config.h"
 #include <stddef.h>
 
-#if ENABLE_THREADS != 0 && !defined(NDEBUG)
+#if LLVM_ENABLE_THREADS != 0 && !defined(NDEBUG)
 // tsan (Thread Sanitizer) is a valgrind-based tool that detects these exact
 // functions by name.
 extern "C" {
-LLVM_ATTRIBUTE_NOINLINE void AnnotateHappensAfter(const char *file, int line,
-                                                  const volatile void *cv);
-LLVM_ATTRIBUTE_NOINLINE void AnnotateHappensBefore(const char *file, int line,
-                                                   const volatile void *cv);
-LLVM_ATTRIBUTE_NOINLINE void AnnotateIgnoreWritesBegin(const char *file,
-                                                       int line);
-LLVM_ATTRIBUTE_NOINLINE void AnnotateIgnoreWritesEnd(const char *file,
-                                                     int line);
+LLVM_ATTRIBUTE_WEAK void AnnotateHappensAfter(const char *file, int line,
+                                              const volatile void *cv);
+LLVM_ATTRIBUTE_WEAK void AnnotateHappensBefore(const char *file, int line,
+                                               const volatile void *cv);
+LLVM_ATTRIBUTE_WEAK void AnnotateIgnoreWritesBegin(const char *file, int line);
+LLVM_ATTRIBUTE_WEAK void AnnotateIgnoreWritesEnd(const char *file, int line);
 }
 #endif
 
@@ -44,7 +42,7 @@ namespace sys {
   // Otherwise valgrind may continue to execute the old version of the code.
   void ValgrindDiscardTranslations(const void *Addr, size_t Len);
 
-#if ENABLE_THREADS != 0 && !defined(NDEBUG)
+#if LLVM_ENABLE_THREADS != 0 && !defined(NDEBUG)
   // Thread Sanitizer is a valgrind tool that finds races in code.
   // See http://code.google.com/p/data-race-test/wiki/DynamicAnnotations .