#include "Types.h"
#include "Locks.cpp"
#include "linux/Locks.h"
Go to the source code of this file.
Namespaces | |
namespace | MPMA |
Classes | |
class | MPMA::RWSleepLock |
ReaderWriter sleep-lock (re-entrant safe). Read locks don't block each other out, but Write locks are exclusive to all other locks. More... | |
class | MPMA::TakeRWSleepLock |
Used to lock/unlock a RWSleepLock automatically using scope. The lock is released on dustruction. More... | |
class | MPMA::MutexLock |
Mutex (re-entrant safe). More... | |
class | MPMA::TakeMutexLock |
Used to lock/unlock a MutexLock automatically using scope. The lock is released on dustruction. More... | |
class | MPMA::SpinLock |
Spinlock (NOT re-entrant safe) that reverts to a sleeplock on single cpu systems. If no lock-contention occurs, these is extremely little overhead in use. More... | |
class | MPMA::TakeSpinLock |
Used to lock/unlock a spinlock automatically using scope. The lock is released on destruction. More... | |
class | MPMA::BlockingObject |
An object that can be used to block a thread until another thread signals it to resume. More... | |
Functions | |
void | MPMA::AtomicIntInc (volatile uint *pint) |
Atomically increments an integer. | |
void | MPMA::AtomicIntDec (volatile uint *pint) |
Atomically decrements an integer. | |
int | MPMA::AtomicIntAdd (volatile int *pint, int addValue) |
Atomically adds one integer to another and returns the value of the original. | |
bool | MPMA::AtomicCompareExchange (volatile uint *pInt, uint expectedValue, uint newValue, volatile uint &outResultValue) |
Compares expectedValue with the value at pInt, and if they are the same, sets pInt to newValue and returns true with outResultValue set to newValue. If they are different then pInt is unaffected, and returns false with outResultValue set to the value that was found at pInt. |