Definition
Dispatcher
Functions
The dispatcher performs the following critical tasks during a context switch:
- Saving Context: Storing the state of the previously running process in its PCB.
- Loading Context: Restoring the state of the new process from its PCB.
- Switching Modes: Transitioning the processor from kernel mode to user mode.
- Jumping: Moving the program counter to the proper location in the user program to resume execution.
Dispatch Latency
The time it takes for the dispatcher to stop one process and start another is known as dispatch latency. This latency is a pure overhead and should be minimised to ensure high system responsiveness.