diff --git a/etc/tsansup.txt b/etc/tsansup.txt index 37c69805f..fd4028e0f 100644 --- a/etc/tsansup.txt +++ b/etc/tsansup.txt @@ -13,10 +13,6 @@ race:BloombergLP::bdlma::ConcurrentPool::deleteObject # attempts to explain why there is no race. race:BloombergLP::bcema_Pool<*>::allocate -# Not sure what the problem is here, but tsan can't show the other stack, so -# there's nothing to look into -#race:__tsan_atomic32_fetch_add - # Don't warn about using cout from multiple threads race:std::basic_ostream& bsl::operator<< <*>(std::basic_ostream<*>&, bsl::basic_string<*> const&) @@ -24,11 +20,14 @@ race:std::basic_ostream& bsl::operator<< <*>(std::basic_ostream<*>&, bs # it makes tsan warn in some cases race:BloombergLP::ball::LoggerManager::isInitialized() -# Suppress TSan report in a routine used in bmqimp::Brokersession test driver. -# It is a benign race in the test driver, but should be looked into at some -# point. -#race:TestSession::waitForChannelClose -#race:TestSession::arriveAtStepWithCfgs +# Suppress sporadically appearing data race in bmqimp::Brokersession test driver. +# In TestSession::arriveAtStepWithCfgs() there is a call of queue->setOptions() method, +# at nearly same time in other thread bmqimp::BrokerSession::onConfigureQueueResponse() calls +# queue->options().suspendsOnBadHostHealth() method which is detected as data race. +# bmqt::QueueOptions and bmqimp::Queue classes are not thread safe by design, +# and bmqimp::BrokerSession::onConfigureQueueResponse() cllback access them in +# not thread-safe manner, probably also by design, assuming that it will be called again +# if something is changed. Further investigation is required, suppress it for now. race:BloombergLP::bmqt::QueueOptions::suspendsOnBadHostHealth # Since we use mqbmock::Dispatcher in unit tests, this method does not get diff --git a/etc/ubsansup.txt b/etc/ubsansup.txt index 32a6901b5..5f5613957 100644 --- a/etc/ubsansup.txt +++ b/etc/ubsansup.txt @@ -1,6 +1,2 @@ -# bmqp::Crc32c carries out misaligned access of Int64 in one of the internal -# routines, but only on x86/64. Misaligned accesses are handled gracefully by -# this hardware, unlike SPARC. So we simply suppress this warning. Other -# option is to update the code, which can be done by someone feeling -# adventurous. -# alignment:crc32c1024SseInt +# UndefinedBehaviorSanitizer suppressions file for BMQ. +# See details https://clang.llvm.org/docs/UndefinedBehaviorSanitizer.html#runtime-suppressions. diff --git a/src/groups/mwc/mwcio/mwcio_testchannel.h b/src/groups/mwc/mwcio/mwcio_testchannel.h index 49357b561..05fd0b349 100644 --- a/src/groups/mwc/mwcio/mwcio_testchannel.h +++ b/src/groups/mwc/mwcio/mwcio_testchannel.h @@ -248,7 +248,9 @@ class TestChannel : public Channel { /// Pops a close-call from those written to the channel (FIFO ordering). CloseCall popCloseCall(); - bool closeCallsEmpty(); + /// Lock mutex and return `true` if d_closeCalls collection is empty, + /// `false` otherwise. + bool closeCallsEmpty(); CloseSignaler& closeSignaler();