Ask Question

Of these two types of programs:a. I/O - bound b. CPU - bound which is more likely to have voluntary context switches, and which is more likely to have nonvoluntary context switches? Explain your answer.

+2
Answers (1)
  1. 9 May, 22:55
    0
    For I/O-bound we require voluntary context switches.

    For CPU-bound we require non-voluntary context switches.

    Explanation:

    A voluntary context switches occurs when process has given up control of the CPU because it requires a resource that is currently unavailable (such as blocking for I/O). It happen frequently in normal system operation. Voluntary context switching initiated with a call to the sleep () routine.

    A non-voluntary context switches occurs when the CPU has taken away from a process, such as when it's time slice has expired or it has been preempted by a high-priority process. It is forced by direct invocation of the low-level context-switching mechanism embodied in the mi_switch () and setrunnable () routines.
Know the Answer?
Not Sure About the Answer?
Find an answer to your question 👍 “Of these two types of programs:a. I/O - bound b. CPU - bound which is more likely to have voluntary context switches, and which is more ...” in 📗 Computers & Technology if the answers seem to be not correct or there’s no answer. Try a smart search to find answers to similar questions.
Search for Other Answers