CMSC 421 Exam 2 Review Guide ACTUAL UPDATED QUESTIONS AND CORRECT
ANSWERS
What is the basis of multiprogrammed operating CPU scheduling. Its objective is to maximize CPU utilization by having some
systems? process running at all times.
What is the fundamental unit of computation being Kernel-level threads. Although the terms "process scheduling" and "thread
scheduled on modern operating systems? scheduling" are often used interchangeably.
Describe the CPU-I/O burst cycle. Process execution consists of an alternating cycle of CPU execution (CPU burst)
and I/O wait (I/O burst). It starts with a CPU burst and eventually ends with a final
CPU burst followed by a system request to terminate.
What is a characteristic of an I/O-bound program in It typically has many short CPU bursts.
terms of CPU bursts?
What is a characteristic of a CPU-bound program in terms It might have a few long CPU bursts.
of CPU bursts?
What is the role of the CPU scheduler? It selects a process from the processes in the ready queue that are ready to
execute and allocates the CPU to that process when the CPU becomes idle.
Name the four circumstances under which CPU- 1. Process switches from running to waiting state. 2. Process switches from running
scheduling decisions may take place. to ready state (e.g., interrupt). 3. Process switches from waiting to ready state (e.g.,
I/O completion). 4. Process terminates.
, What is Nonpreemptive (or cooperative) scheduling? Scheduling that only takes place when a process switches from running to waiting
(1) or when a process terminates (4). The process keeps the CPU until it releases it.
What is Preemptive Scheduling? Scheduling that can take place when a process switches from running to ready (2)
or from waiting to ready (3). The CPU can be taken away from a process.
What potential issue can preemptive scheduling It can result in race conditions when data is shared among several processes, as
introduce? one process may be preempted while updating shared data.
What is the role of the Dispatcher? The module that gives control of the CPU's core to the process selected by the
CPU scheduler.
What are the three functions of the Dispatcher? 1. Switching context from one process to another. 2. Switching to user mode. 3.
Jumping to the proper location in the user program to resume that program.
What is Dispatch Latency? The time it takes for the dispatcher to stop one process and start another running.
It should be as fast as possible.
What is a Voluntary Context Switch? Occurs when a process gives up control of the CPU because it requires a
resource that is currently unavailable (e.g., blocking for I/O).
What is a Nonvoluntary Context Switch? Occurs when the CPU is taken away from a process, such as when its time slice
expires or it is preempted by a higher-priority process.
CPU Utilization The goal is to maximize this. It is the fraction of time the CPU is busy, typically
ranging from 40% (lightly loaded) to 90% (heavily loaded).
Throughput The number of processes that are completed per time unit. It is a measure of the
work being accomplished. (Maximize)
Turnaround Time The total interval from submission to completion of a process. It is the sum of time
spent waiting in the ready queue, executing on the CPU, and performing I/O.
(Minimize)
Waiting Time The total amount of time a process spends waiting in the ready queue. This is the
only criterion directly affected by the CPU-scheduling algorithm. (Minimize)
Response Time The time from the submission of a request until the first response is produced (the
time it takes to start responding). This is critical in interactive systems. (Minimize)
What is often considered more important than minimizing Minimizing the variance in response time. A system with a predictable response
the average response time in interactive systems? time is often more desirable than one that is faster on average but highly variable.
ANSWERS
What is the basis of multiprogrammed operating CPU scheduling. Its objective is to maximize CPU utilization by having some
systems? process running at all times.
What is the fundamental unit of computation being Kernel-level threads. Although the terms "process scheduling" and "thread
scheduled on modern operating systems? scheduling" are often used interchangeably.
Describe the CPU-I/O burst cycle. Process execution consists of an alternating cycle of CPU execution (CPU burst)
and I/O wait (I/O burst). It starts with a CPU burst and eventually ends with a final
CPU burst followed by a system request to terminate.
What is a characteristic of an I/O-bound program in It typically has many short CPU bursts.
terms of CPU bursts?
What is a characteristic of a CPU-bound program in terms It might have a few long CPU bursts.
of CPU bursts?
What is the role of the CPU scheduler? It selects a process from the processes in the ready queue that are ready to
execute and allocates the CPU to that process when the CPU becomes idle.
Name the four circumstances under which CPU- 1. Process switches from running to waiting state. 2. Process switches from running
scheduling decisions may take place. to ready state (e.g., interrupt). 3. Process switches from waiting to ready state (e.g.,
I/O completion). 4. Process terminates.
, What is Nonpreemptive (or cooperative) scheduling? Scheduling that only takes place when a process switches from running to waiting
(1) or when a process terminates (4). The process keeps the CPU until it releases it.
What is Preemptive Scheduling? Scheduling that can take place when a process switches from running to ready (2)
or from waiting to ready (3). The CPU can be taken away from a process.
What potential issue can preemptive scheduling It can result in race conditions when data is shared among several processes, as
introduce? one process may be preempted while updating shared data.
What is the role of the Dispatcher? The module that gives control of the CPU's core to the process selected by the
CPU scheduler.
What are the three functions of the Dispatcher? 1. Switching context from one process to another. 2. Switching to user mode. 3.
Jumping to the proper location in the user program to resume that program.
What is Dispatch Latency? The time it takes for the dispatcher to stop one process and start another running.
It should be as fast as possible.
What is a Voluntary Context Switch? Occurs when a process gives up control of the CPU because it requires a
resource that is currently unavailable (e.g., blocking for I/O).
What is a Nonvoluntary Context Switch? Occurs when the CPU is taken away from a process, such as when its time slice
expires or it is preempted by a higher-priority process.
CPU Utilization The goal is to maximize this. It is the fraction of time the CPU is busy, typically
ranging from 40% (lightly loaded) to 90% (heavily loaded).
Throughput The number of processes that are completed per time unit. It is a measure of the
work being accomplished. (Maximize)
Turnaround Time The total interval from submission to completion of a process. It is the sum of time
spent waiting in the ready queue, executing on the CPU, and performing I/O.
(Minimize)
Waiting Time The total amount of time a process spends waiting in the ready queue. This is the
only criterion directly affected by the CPU-scheduling algorithm. (Minimize)
Response Time The time from the submission of a request until the first response is produced (the
time it takes to start responding). This is critical in interactive systems. (Minimize)
What is often considered more important than minimizing Minimizing the variance in response time. A system with a predictable response
the average response time in interactive systems? time is often more desirable than one that is faster on average but highly variable.