Extend default blacklist logic to MSan and TSan.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@182269 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Driver/SanitizerArgs.h b/lib/Driver/SanitizerArgs.h
index 326d80d..1f7ec99 100644
--- a/lib/Driver/SanitizerArgs.h
+++ b/lib/Driver/SanitizerArgs.h
@@ -203,10 +203,16 @@
static bool getDefaultBlacklistForKind(const Driver &D, unsigned Kind,
std::string &BLPath) {
- // For now, specify the default blacklist location for ASan only.
- if (Kind & NeedsAsanRt) {
+ const char *BlacklistFile = 0;
+ if (Kind & NeedsAsanRt)
+ BlacklistFile = "asan_blacklist.txt";
+ else if (Kind & NeedsMsanRt)
+ BlacklistFile = "msan_blacklist.txt";
+ else if (Kind & NeedsTsanRt)
+ BlacklistFile = "tsan_blacklist.txt";
+ if (BlacklistFile) {
SmallString<64> Path(D.ResourceDir);
- llvm::sys::path::append(Path, "asan_blacklist.txt");
+ llvm::sys::path::append(Path, BlacklistFile);
BLPath = Path.str();
return true;
}