#include <revolution/os.h>
typedef void (*OSSwitchThreadCallback)(OSThread* from, OSThread* to);
OSSwitchThreadCallback
OSSetSwitchThreadCallback( OSSwitchThreadCallback callback );
|
Callback function to call whenever a thread context switch occurs. Specify NULL to cancel the callback function. |
The previous thread switch callback.
Registers a specified callback function. This callback function is called whenever a thread context switch occurs.
callback takes two arguments. from is a pointer to the previously running thread. to is a pointer to the next running thread. If no thread is ready to run, either from or to will be NULL.
Thread Functions, Thread Synchronization Functions, OSCancelThread, OSDetachThread, OSExitThread, OSIsThreadTerminated
03/01/2006 Initial version.