Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -636,7 +636,12 @@ io_uring_scheduler::post(std::coroutine_handle<> h) const
{
auto saved = h_;
delete this;
// TSan cannot instrument standalone fences; this acquire
// pairs with the posting thread's release and is intentional.
BOOST_COROSIO_GCC_WARNING_PUSH
BOOST_COROSIO_GCC_WARNING_DISABLE("-Wtsan")
std::atomic_thread_fence(std::memory_order_acquire);
BOOST_COROSIO_GCC_WARNING_POP
saved.resume();
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -490,8 +490,13 @@ reactor_scheduler::post(std::coroutine_handle<> h) const
{
auto saved = h_;
delete this;
// Ensure stores from the posting thread are visible
// Ensure stores from the posting thread are visible. TSan
// cannot instrument standalone fences; this acquire pairs
// with the posting thread's release and is intentional.
BOOST_COROSIO_GCC_WARNING_PUSH
BOOST_COROSIO_GCC_WARNING_DISABLE("-Wtsan")
std::atomic_thread_fence(std::memory_order_acquire);
BOOST_COROSIO_GCC_WARNING_POP
saved.resume();
}

Expand Down
6 changes: 6 additions & 0 deletions test/unit/Jamfile
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,12 @@ project boost/corosio/test/unit
<target-os>windows:<define>_WIN32_WINNT=0x0602
<warnings>extra
<warnings-as-errors>on
# GCC mis-analyzes the structured-binding-from-co_await idiom
# (auto [ec, ...] = co_await op) in coroutine frames and reports a
# bogus -Wmaybe-uninitialized. The pattern is unavoidable and used by
# most async tests, so suppress it for GCC across the test project.
# (The library itself is clean; see capy test/unit/Jamfile.)
<toolset>gcc:<cxxflags>-Wno-maybe-uninitialized
;

# Non-TLS tests (recurses into test/, native/, etc.)
Expand Down
Loading