GATE | GATE IT 2006 | Question 12
In the working-set strategy, which of the following is done by the operating system to prevent thrashing?
- It initiates another process if there are enough extra frames.
- It selects a process to suspend if the sum of the sizes of the working-sets exceeds the total number of available frames.
(A) I only
(B) II only
(C) Neither I nor II
(D) Both I and II
Explanation: According to concept of thrashing,
- I is true because to prevent thrashing we must provide processes with as many frames as they really need “right now”.If there are enough extra frames, another process can be initiated.
- II is true because The total demand, D, is the sum of the sizes of the working sets for all processes. If D exceeds the total number of available frames, then at least one process is thrashing, because there are not enough frames available to satisfy its minimum working set. If D is significantly less than the currently available frames, then additional processes can be launched.