projects
/
oota-llvm.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Silence tsan false-positives (tsan can't track things which are only safe due to
[oota-llvm.git]
/
lib
/
Support
/
Statistic.cpp
diff --git
a/lib/Support/Statistic.cpp
b/lib/Support/Statistic.cpp
index 04a44a0f7113429d8d36f51b8a3304897e07115f..d8a6ad35ba9cae8805ab9c9f3c1cef2ace2d1ba6 100644
(file)
--- a/
lib/Support/Statistic.cpp
+++ b/
lib/Support/Statistic.cpp
@@
-73,9
+73,12
@@
void Statistic::RegisterStatistic() {
if (Enabled)
StatInfo->addStatistic(this);
+ TsanHappensBefore(this);
sys::MemoryFence();
// Remember we have been registered.
+ TsanIgnoreWritesBegin();
Initialized = true;
+ TsanIgnoreWritesEnd();
}
}