1 votes 1 votes in round robin algorithm if a process with burst time = 10 arrived at t=0 and time quantum is 2 units, context switch time is 2 units . Then completion time of the process will be? Operating System operating-system process-scheduling round-robin-scheduling context-switch + – jayadev asked Oct 10, 2021 jayadev 1.3k views answer comment Share Follow See all 0 reply Please log in or register to add a comment.
0 votes 0 votes Arrival time = 0, Burst time = 10 units, Time quantum = 2 units and Context switch time = 2 units. Ready queue = P1 P1 P1 P1 P1 P1 P1 P1 P1 P1 0 2 4 6 8 10 12 14 16 18 Number of context switch = 4 so CS time = 4*2 = 8 Completion time = 8 + 10 = 18 units. Aashay kaurav answered Oct 10, 2021 Aashay kaurav comment Share Follow See all 4 Comments See all 4 4 Comments reply Shaik Masthan commented Oct 11, 2021 reply Follow Share if the same process again getting the turn, then it requires CONTEXT SWITCH ? - depends upon implementation of OS 0 votes 0 votes Aashay kaurav commented Oct 11, 2021 reply Follow Share It do sir, but we can assume windows OS which implements RR and CS happens for the single process. 0 votes 0 votes Shaik Masthan commented Oct 11, 2021 reply Follow Share implementation depends question - will not ask in GATE. you can't give any assurance that, question based on Windows OS( as you said, Windows Os can do CS for one process.) 0 votes 0 votes aaaakash001 commented Nov 11, 2022 reply Follow Share Is context switching required for only one process in Round robin scheduling ? Yes, even if there is just 1 process, after using up its time slice, it would save the current execution state, go back to the ready queue and be scheduled to run again. if we have only one process of 10 time units. If the quantum is 12 time units, the process finishes in less than 1 time quantum, with no overhead. If the quantum is 6 time units, however, the process requires 2 quanta, resulting in a context switch. If the time quantum is 1 time unit, then nine context switches will occur, slowing the execution of the process accordingly 0 votes 0 votes Please log in or register to add a comment.