![]() Interactive processes should do I/O before being preempted, so that unnecessary preemptions are avoided. The smaller the quantum, the larger the proportion of the time used in context switches. #Kernel retrieve timeslice used how to#In the Round Robin algorithm, each process is given an equal quantum the big question is how to choose the time quantum. I/O), like in other preemptive algorithms. The process may also relinquish its quantum by doing a blocking system call (i.e. To achieve this, the running process is given a variable that starts at its quantum, and is then decremented each tick until it reaches zero. For example, if the timer runs at 100Hz, and a process' quantum is 10 ticks, it may run for 100 milliseconds (10/100 of a second). This quantum dictates the number of system timer ticks the process may run for before being preempted. When the system timer fires, the next process in the queue is switched to, and the preempted process is put back into the queue.Įach process is assigned a time slice or "quantum". Only a single queue of processes is used. Round Robin is the simplest algorithm for a preemptive scheduler.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |