17 #include "llvm/Config/config.h"
19 #if HAVE_VALGRIND_VALGRIND_H
20 #include <valgrind/valgrind.h>
22 static bool InitNotUnderValgrind() {
23 return !RUNNING_ON_VALGRIND;
30 static const bool NotUnderValgrind = InitNotUnderValgrind();
35 return RUNNING_ON_VALGRIND;
42 VALGRIND_DISCARD_TRANSLATIONS(Addr, Len);
45 #else // !HAVE_VALGRIND_VALGRIND_H
54 #endif // !HAVE_VALGRIND_VALGRIND_H
56 #if LLVM_ENABLE_THREADS != 0 && !defined(NDEBUG)
61 const volatile void *cv) {}
63 const volatile void *cv) {}
void AnnotateHappensBefore(const char *file, int line, const volatile void *cv)
void ValgrindDiscardTranslations(const void *Addr, size_t Len)
void AnnotateIgnoreWritesBegin(const char *file, int line)
void AnnotateIgnoreWritesEnd(const char *file, int line)
void AnnotateHappensAfter(const char *file, int line, const volatile void *cv)