12 #ifndef K_API_ATOMIC_H
13 #define K_API_ATOMIC_H
90 #define kAtomic32s_Init_(ATM, VAL) kxAtomic32s_Init_(ATM, VAL)
91 #define kAtomic32s_Increment_(ATM) kxAtomic32s_Increment_(ATM)
92 #define kAtomic32s_Decrement_(ATM) kxAtomic32s_Decrement_(ATM)
93 #define kAtomic32s_Exchange_(ATM, VAL) kxAtomic32s_Exchange_(ATM, VAL)
94 #define kAtomic32s_CompareExchange_(ATM, OLD, VAL) kxAtomic32s_CompareExchange_(ATM, OLD, VAL)
95 #define kAtomic32s_Get_(ATM) kxAtomic32s_Get_(ATM)
150 #define kAtomicPointer_Init_(ATM, VAL) kxAtomicPointer_Init_(ATM, VAL)
151 #define kAtomicPointer_Exchange_(ATM, VAL) kxAtomicPointer_Exchange_(ATM, VAL)
152 #define kAtomicPointer_CompareExchange_(ATM, OLD, VAL) kxAtomicPointer_CompareExchange_(ATM, OLD, VAL)
153 #define kAtomicPointer_Get_(ATM) kxAtomicPointer_Get_(ATM)
159 #include <kApi/Threads/kAtomic.x.h>
Represents a void pointer.
k32s kAtomic32s_Increment(kAtomic32s *atomic)
Increments an atomic variable.
kBool kAtomic32s_CompareExchange(kAtomic32s *atomic, k32s oldValue, k32s value)
Conditionally exchanges the value of an atomic variable.
kBool kAtomicPointer_CompareExchange(kAtomicPointer *atomic, kPointer oldValue, kPointer value)
Conditionally exchanges the value of an atomic variable.
Represents a 32-bit, atomically-accessed, signed integer.
Core Zen type declarations.
Represents a 32-bit signed integer.
k32s kAtomic32s_Decrement(kAtomic32s *atomic)
Decrements an atomic variable.
Represents an atomically-accessed pointer.
Represents a boolean value.
k32s kAtomic32s_Exchange(kAtomic32s *atomic, k32s value)
Exchanges the value of an atomic variable.
kPointer kAtomicPointer_Exchange(kAtomicPointer *atomic, kPointer value)
Exchanges the value of an atomic variable.
k32s kAtomic32s_Get(kAtomic32s *atomic)
Gets the current value of an atomic variable.
kPointer kAtomicPointer_Get(kAtomicPointer *atomic)
Gets the current value of an atomic variable.