pallavi agarwal
pallavi agarwal
Branch Unspecified
13 May 2012

Round Robin Technique

Hello all, This is Pallavi. I want to know what is round robin technique? It is a scheduling algorithm. 👍
mahul

mahul

Branch Unspecified
10 years ago
can u mention the context?? It would help everyone answer your questions better. If i'm not mistaken you are probably talking of scheduling algorithms.

Well a round robin scheduling algorithm ensures that every job( e.g. process) gets a fixed and equal amount of resource(e.g CPU time). For example if you have 10 processes and 10ms time burst, the first process gets a time of 10secs, next gets the time between 10-20 and then the next is scheduled and so on, even if the process is not completed. If it is, then immediately the next is scheduled( the cpu wont sit idle for the remainder of the 10 mseconds).
apple6

apple6

Branch Unspecified
6 years ago
Round Robin scheduling algorithm :- This is one of the CPU scheduling algorithm.
Round Robin calls for the distribution of the processing time equally among all the processes requesting the processor.
To accomplish the above task, the technique has to choose a time quantum or a time slice.
Time quantum :- The period of time for which a process is allowed to run uninterrupted in a preemptive multitasking operating system.
So, each process gets equal share of the CPU. The technique works as follows: initially run the process for one time slice, then move to back of queue.
Round Robin algorithm is clearly explained with the below example:
consider the following processes & their brust time
Process Burst time
P1 24
P2 3
P3 3
For suppose, consider the Time quantum =4
Initally, the process p1 is executed for a time slice of 4 & then come to process p2.
Since p2 requires only 3ms which is less than the time quantum chosen, the process p2 gets completely executed.
Process p3 also requires 3ms which is less than our choosen time quantum, the process p3 also gets completely executed.
And again comes back to p1 & executes it for the time quantum considered(4).No need execute the processes p2 & p3 since they are completed.
The execution can be represented as follows:
Gantt chart:
P1 P2 P3 P1 P1 P1 P1 P1
0 4 7 10 14 18 22 26 30
Initally,p1 need not to wait so,the waiting time for p1 is 0 & it is executed for 4ms & then p2 (4+3=7) & p3(7+3=10). And then comes back to p1 and executes it....
Turnaround time (Time between submisson and completion) is typically larger.
The performance depends on the time quantum:
Small time quantum: Overhead due to context switches (& scheduling)
Large time quantum: Behaves like FCFS
Ankita Katdare

Ankita Katdare

Computer Science
6 years ago
apple6 Good explanation.. 👍
Ankita Katdare

Ankita Katdare

Computer Science
6 years ago
apple6 Good explanation.. 👍
apple6

apple6

Branch Unspecified
6 years ago
thanks for your comment.

Share this content on your social channels -

Only logged in users can reply.