WUT  0.1
Wii U Toolchain
Data Structures | Macros | Typedefs | Functions
Condition Variable

Data Structures

struct  OSCondition
 

Macros

#define OS_CONDITION_TAG   0x634E6456u
 

Typedefs

typedef struct OSCondition OSCondition
 
typedef struct OSMutex OSMutex
 

Functions

void OSInitCond (OSCondition *condition)
 
void OSInitCondEx (OSCondition *condition, const char *name)
 
void OSWaitCond (OSCondition *condition, OSMutex *mutex)
 
void OSSignalCond (OSCondition *condition)
 

Detailed Description

Standard condition variable implementation.

Similar to std::condition_variable.

Macro Definition Documentation

#define OS_CONDITION_TAG   0x634E6456u

Definition at line 22 of file condition.h.

Typedef Documentation

typedef struct OSCondition OSCondition

Definition at line 19 of file condition.h.

typedef struct OSMutex OSMutex

Definition at line 20 of file condition.h.

Function Documentation

void OSInitCond ( OSCondition condition)

Initialise a condition variable structure.

void OSInitCondEx ( OSCondition condition,
const char *  name 
)

Initialise a condition variable structure with a name.

void OSWaitCond ( OSCondition condition,
OSMutex mutex 
)

Sleep the current thread until the condition variable has been signalled.

The mutex must be locked when entering this function. Will unlock the mutex and then sleep, reacquiring the mutex when woken.

Similar to std::condition_variable::wait.

void OSSignalCond ( OSCondition condition)

Will wake up any threads waiting on the condition with OSWaitCond.

Similar to std::condition_variable::notify_all.