9#ifndef CPPCOMMON_THREADS_SPIN_BARRIER_H
10#define CPPCOMMON_THREADS_SPIN_BARRIER_H
46 int threads() const noexcept {
return _threads; }
57 std::atomic<
int> _counter;
58 std::atomic<
int> _generation;
66#include "spin_barrier.inl"
Spin barrier synchronization primitive.
SpinBarrier & operator=(SpinBarrier &&)=delete
int threads() const noexcept
Get the count of threads to wait at the barrier.
SpinBarrier(const SpinBarrier &)=delete
bool Wait() noexcept
Wait at the barrier until all other threads reach this barrier.
SpinBarrier(SpinBarrier &&)=delete
SpinBarrier & operator=(const SpinBarrier &)=delete
C++ Common project definitions.