di 0.1.0
Loading...
Searching...
No Matches
di::sync Namespace Reference

Classes

struct  AdoptLock
 
class  Atomic
 
class  AtomicRef
 
struct  DeferLock
 
class  DumbConditionVariable
 
class  DumbSpinlock
 
class  InPlaceStopCallback
 
class  InPlaceStopSource
 
class  InPlaceStopToken
 
class  NeverStopToken
 
class  ScopedLock
 
class  Synchronized
 
struct  TryToLock
 
class  UniqueLock
 

Typedefs

template<typename Value, concepts::Lock Lock = DefaultLock>
using LockedReference = util::GuardedReference<Value, ScopedLock<Lock>>
 

Enumerations

enum class  MemoryOrder : int {
  Relaxed = __ATOMIC_RELAXED , Consume = __ATOMIC_CONSUME , Acquire = __ATOMIC_ACQUIRE , Release = __ATOMIC_RELEASE ,
  AcquireRelease = __ATOMIC_ACQ_REL , SequentialConsistency = __ATOMIC_SEQ_CST
}
 

Functions

void cpu_relax ()
 
template<typename Callback>
 InPlaceStopCallback (InPlaceStopToken, Callback) -> InPlaceStopCallback< Callback >
 
template<typename T>
 Synchronized (T &&) -> Synchronized< T >
 

Variables

constexpr auto defer_lock = DeferLock {}
 
constexpr auto try_to_lock = TryToLock {}
 
constexpr auto adopt_lock = AdoptLock {}
 

Typedef Documentation

◆ LockedReference

template<typename Value, concepts::Lock Lock = DefaultLock>
using di::sync::LockedReference = util::GuardedReference<Value, ScopedLock<Lock>>

Enumeration Type Documentation

◆ MemoryOrder

enum class di::sync::MemoryOrder : int
strong
Enumerator
Relaxed 
Consume 
Acquire 
Release 
AcquireRelease 
SequentialConsistency 

Function Documentation

◆ cpu_relax()

void di::sync::cpu_relax ( )
inline

◆ InPlaceStopCallback()

template<typename Callback>
di::sync::InPlaceStopCallback ( InPlaceStopToken ,
Callback  ) -> InPlaceStopCallback< Callback >

◆ Synchronized()

template<typename T>
di::sync::Synchronized ( T && ) -> Synchronized< T >

Variable Documentation

◆ adopt_lock

auto di::sync::adopt_lock = AdoptLock {}
inlineconstexpr

◆ defer_lock

auto di::sync::defer_lock = DeferLock {}
inlineconstexpr

◆ try_to_lock

auto di::sync::try_to_lock = TryToLock {}
inlineconstexpr