next up previous contents index
Next: 25.6.2 pthread_sched_donate_wait_recv: Donate CPU Up: 25.6 CPU Inheritance Framework Previous: 25.6 CPU Inheritance Framework

25.6.1 pthread_sched_become_scheduler: Become an application level scheduler

 

SYNOPSIS

#include <oskit/threads/pthread.h>
#include <oskit/threads/cpuinherit.h>

void pthread_sched_become_scheduler(void);

DESCRIPTION

Inform the CPU inheritance framework that the current thread is an application level scheduler. Certain initializations are performed that allow the current thread to donate its own CPU resources to other threads, and to receive scheduling messages regarding threads under its controls. Once this call is performed, the thread will generally enter a loop waiting for scheduling messages to inform it of new threads that it needs to schedule, or changes in the status of threads already under its control. For example, when a thread blocked on a mutex finally takes the mutex, an unblock message will be sent to that thread's scheduler informing it that the thread in question should now be run.



Utah Flux Research Group