1,652 views

3 Answers

Best answer
8 votes
8 votes
Let us discussion about option A) and B) first since both of them are related to timer.First of all , we should know that timer is a device which lets us know if a process needs to be preempted or not.

Timer expire is also a kind of interrupt which occurs in time sharing system and in other words we can say Round Robin Algo is involved.Whenever a process is scheduled and dispatched from ready state to running state , the timer is initialised to value equal to time quantum.Hence A) option is valid.

Now if a process needs to execute for a time slice less than the time quantum decided earlier , then process is completed and sent to termination state.But if it is larger then , it executes for a time quantum as a result of which timer value becomes 0 after completion of time quantum.Hence after this , "timer expires" interrupt occurs and as a result the process is placed at the tail of the ready queue once again and hence in ready state.Here we have to keep in mind that timer is used specifically in case of Round Robin Algorithm since there is requirement of equal time quantum after every preemption.

So the conclusion is that "timer expires" is a special type of interrupt that involves transition from running state to ready state and not to I/O wait state since we go to I/O state to service interrupts which are caused due to I/O devices.Hence , B) option is invalid.

As stated earlier , I/O  results in transition from running state to I/O wait state not ready state.Hence C) option is also invalid.

Resuming of process is done by mid term scheduler either from suspend I/O wait to I/O wait state in case the I/O resources become sufficient or from suspend ready to ready state.Hence D) option is invalid as well.

 

Hence B),C) and D) options are invalid.
selected by
0 votes
0 votes
Answer is C

I/O: running->ready is wrong.
It should be  I/O: running->blocked
0 votes
0 votes

Ans is - D. As there is no transition from Suspended state to running directly. It first has to go to ready state.

Related questions

0 votes
0 votes
3 answers
1
Chaitanya Kale asked Sep 22, 2022
629 views
If we are using non-preemptive CPU scheduling then can there be process state transition from running to ready state?
1 votes
1 votes
1 answer
2
iarnav asked Jan 12, 2022
385 views
Does non preemptive CPU scheduling needs hardware support.kindly explain.
1 votes
1 votes
1 answer
4
Ram Ahuja asked Feb 13, 2019
2,745 views
In which of the following case CPU utilization will be higher?(a) If all the processes are I/O bound(b) Is all the processes are equally CPU bound and I/O bound(c) If all...