summaryrefslogtreecommitdiffstats
path: root/clang/utils/TableGen/TableGen.cpp
diff options
context:
space:
mode:
authorKostya Serebryany <kcc@google.com>2014-01-10 08:05:42 +0000
committerKostya Serebryany <kcc@google.com>2014-01-10 08:05:42 +0000
commita6afef7a512314e078054038c391c2903d608a13 (patch)
tree11d38470a09f4dffe10e4381cc5eb590e678d49b /clang/utils/TableGen/TableGen.cpp
parent27f5b8800d1ec5f60599936ab7398d5bb44610b3 (diff)
downloadbcm5719-llvm-a6afef7a512314e078054038c391c2903d608a13.tar.gz
bcm5719-llvm-a6afef7a512314e078054038c391c2903d608a13.zip
reapply r198858: Disable LeakSanitizer in TableGen binaries, see PR18325; this time LeakSanitizerIsTurnedOffForTheCurrentProcess is used instead of __lsan_is_turned_off
llvm-svn: 198922
Diffstat (limited to 'clang/utils/TableGen/TableGen.cpp')
-rw-r--r--clang/utils/TableGen/TableGen.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/clang/utils/TableGen/TableGen.cpp b/clang/utils/TableGen/TableGen.cpp
index 4e7624db151..1d677e7a2a1 100644
--- a/clang/utils/TableGen/TableGen.cpp
+++ b/clang/utils/TableGen/TableGen.cpp
@@ -263,3 +263,10 @@ int main(int argc, char **argv) {
return TableGenMain(argv[0], &ClangTableGenMain);
}
+
+extern "C" {
+// Disable LeakSanitizer for this binary as it has too many leaks that are not
+// very interesting to fix. LeakSanitizerIsTurnedOffForTheCurrentProcess is
+// explained in compiler-rt/include/sanitizer/lsan_interface.h
+int LeakSanitizerIsTurnedOffForTheCurrentProcess() { return 1; }
+} // extern "C"
OpenPOWER on IntegriCloud