#include <revolution/os.h> #define OS_THREAD_SPECIFIC_MAX 2 void* OSGetThreadSpecific ( s32 index ); void OSSetThreadSpecific ( s32 index, void* ptr );
| index | Index to the thread-specific data (zero or one). |
|---|---|
| ptr | The thread specific data to set (OSSetThreadSpecific) |
The OSGetThreadSpecific function returns the thread-specific data at index. The OSSetThreadSpecific function does not have a return value.
Gets/sets data specific to the thread that called this function. Each thread can store up to OS_THREAD_SPECIFIC_MAX void pointers in the OSThread structure. When threads are created, thread-specific data is cleared to zero.
Thread Functions, Thread Synchronization Functions, OSCreateThread, OSGetThreadPriority
2006/03/01 Initial version.
CONFIDENTIAL