39 while (_lock.test_and_set(std::memory_order_acquire)){}
45 _lock.clear(std::memory_order_release);
49 std::atomic_flag _lock;
#define POTHOS_API
Definition: Config.hpp:41
void lock(void)
Lock the spin lock, block if already locked.
Definition: SpinLock.hpp:37
Definition: SpinLock.hpp:26
Definition: Testing.hpp:134
SpinLock(void)
Create a new unlocked spin lock.
Definition: SpinLock.hpp:31
void unlock(void)
Unlock the spin lock (should be already locked)
Definition: SpinLock.hpp:43