[ASan] Support comments in ASan/TSan blacklist file as lines starting with #

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166283 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Alexey Samsonov 2012-10-19 15:24:46 +00:00
parent 4a2dec05ce
commit 34674fea97
2 changed files with 5 additions and 0 deletions

View File

@ -45,6 +45,9 @@ BlackList::BlackList(const StringRef Path) {
StringMap<std::string> Regexps;
for (SmallVector<StringRef, 16>::iterator I = Lines.begin(), E = Lines.end();
I != E; ++I) {
// Ignore empty lines and lines starting with "#"
if (I->empty() || I->startswith("#"))
continue;
// Get our prefix and unparsed regexp.
std::pair<StringRef, StringRef> SplitLine = I->split(":");
StringRef Prefix = SplitLine.first;

View File

@ -12,7 +12,9 @@
//
// The blacklist disables instrumentation of various functions and global
// variables. Each line contains a prefix, followed by a wild card expression.
// Empty lines and lines starting with "#" are ignored.
// ---
// # Blacklisted items:
// fun:*_ZN4base6subtle*
// global:*global_with_bad_access_or_initialization*
// global-init:*global_with_initialization_issues*