]> granicus.if.org Git - clang/commitdiff
[AArch64] Enable thread sanitizer on clang
authorRenato Golin <renato.golin@linaro.org>
Wed, 5 Aug 2015 18:42:41 +0000 (18:42 +0000)
committerRenato Golin <renato.golin@linaro.org>
Wed, 5 Aug 2015 18:42:41 +0000 (18:42 +0000)
With this option, clang can use -fsanitize=thread on AArch64.

Patch by Adhemerval Zanella.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@244091 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Driver/ToolChains.cpp

index 8defd5b7e41d5fb1bc2c58bd10766977b4a13497..1e27d0a2df96057d6eaadacb1644eb41be5bfc7f 100644 (file)
@@ -3626,10 +3626,10 @@ SanitizerMask Linux::getSupportedSanitizers() const {
   Res |= SanitizerKind::Vptr;
   if (IsX86_64 || IsMIPS64 || IsAArch64)
     Res |= SanitizerKind::DataFlow;
-  if (IsX86_64 || IsMIPS64) {
+  if (IsX86_64 || IsMIPS64)
     Res |= SanitizerKind::Leak;
+  if (IsX86_64 || IsMIPS64 || IsAArch64)
     Res |= SanitizerKind::Thread;
-  }
   if (IsX86_64 || IsMIPS64 || IsPowerPC64)
     Res |= SanitizerKind::Memory;
   if (IsX86 || IsX86_64) {