Scheduler activations

Operating SystemWindowsMCA

One technique for communication between the user-thread library and the kernel is known as scheduler activation. It works as likes: The kernel provides an application with a set of virtual processors (LWPs), and the application can schedule user threads onto an available virtual processor. Moreover, the kernel must inform an application about certain events. This procedure is known as an upcall. Upcalls are handled by the thread library with an upcall handler, and upcall handlers must run on a virtual processor. One event that triggers an upcall occurs when an application thread is about to block. In this scenario, the kernel makes an upcall to the application informing it that a thread is about to block and identifying the specific thread. Then the kernel allocates a new virtual processor to the application. The application runs an upcall handler on this new virtual processor, that saves the state of the blocking thread and relinquishes the virtual processor on which the blocking thread is running. Another thread that is eligible to run on the new virtual processor is scheduled then by the upcall handler. Whenever the event that the blocking thread was waiting for occurs, the kernel makes another upcall to the thread library informing it that the previously blocked thread is now eligible to run. A virtual processor is also required for The upcall handler for this event, and the kernel may allocate a new virtual processor or preempt one of the user threads and then run the upcall handler on its virtual processor. The application schedules an eligible thread to run on an available virtual processor, after marking the unblocked thread as eligible to run,

raja
Published on 17-Oct-2019 12:34:00
Advertisements