consider a background process that executes for x nanoseconds, then sleeps for y nanoseconds. It never terminates. which transitions will it make according to the 5-state process model? topic:Processes (Operating Systems)
Answers
Answer:
Operating Systems: CPU Scheduling
CPU Scheduling
References:
Abraham Silberschatz, Greg Gagne, and Peter Baer Galvin, "Operating System Concepts, Ninth Edition ", Chapter 6
6.1 Basic Concepts
Almost all programs have some alternating cycle of CPU number crunching and waiting for I/O of some kind. ( Even a simple fetch from memory takes a long time relative to CPU speeds. )
In a simple system running a single process, the time spent waiting for I/O is wasted, and those CPU cycles are lost forever.
A scheduling system allows one process to use the CPU while another is waiting for I/O, thereby making full use of otherwise lost CPU cycles.
The challenge is to make the overall system as "efficient" and "fair" as possible, subject to varying and often dynamic conditions, and where "efficient" and "fair" are somewhat subjective terms, often subject to shifting priority policies.
6.1.1 CPU-I/O Burst Cycle
Almost all processes alternate between two states in a continuing cycle, as shown in Figure 6.1 below :
A CPU burst of performing calculations, and
An I/O burst, waiting for data transfer in or out of the system.
: