projects
/
libcds.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8169c4e
)
TSan exam: fixed intrusive stack test
author
khizmax
<libcds.dev@gmail.com>
Thu, 30 Apr 2015 18:23:12 +0000
(21:23 +0300)
committer
khizmax
<libcds.dev@gmail.com>
Thu, 30 Apr 2015 18:23:12 +0000
(21:23 +0300)
tests/unit/stack/stack_intrusive_pushpop.cpp
patch
|
blob
|
history
diff --git
a/tests/unit/stack/stack_intrusive_pushpop.cpp
b/tests/unit/stack/stack_intrusive_pushpop.cpp
index 4369bf1c6bdcebc2889c2e1919b092351c477ec8..2ed56cd9ddbd1640c50ed268864d203c1cac17e6 100644
(file)
--- a/
tests/unit/stack/stack_intrusive_pushpop.cpp
+++ b/
tests/unit/stack/stack_intrusive_pushpop.cpp
@@
-149,12
+149,14
@@
namespace istack {
while ( !(getTest().m_nWorkingProducers.load(atomics::memory_order_acquire) == 0 && m_Stack.empty()) ) {
typename Stack::value_type * p = m_Stack.pop();
if ( p ) {
+ CDS_TSAN_ANNOTATE_IGNORE_WRITES_BEGIN;
p->nConsumer = m_nThreadNo;
++m_nPopCount;
if ( p->nNo < sizeof(m_arrPop)/sizeof(m_arrPop[0]) )
++m_arrPop[p->nNo];
else
++m_nDirtyPop;
+ CDS_TSAN_ANNOTATE_IGNORE_WRITES_END;
}
else
++m_nPopEmpty;