Unit 2 - Practice Quiz

CSE316

1 Which component of the Operating System is responsible for selecting a process from the ready queue and allocating the CPU to it?

A. Traffic Controller
B. Short-term Scheduler
C. Long-term Scheduler
D. Dispatcher

2 What is the function of the Dispatcher?

A. To select the process for the CPU
B. To give control of the CPU to the process selected by the short-term scheduler
C. To move processes from disk to memory
D. To handle I/O requests

3 Which of the following is not a criterion for CPU scheduling?

A. CPU utilization
B. Throughput
C. Turnaround time
D. Disk bandwidth

4 The time it takes for the dispatcher to stop one process and start another running is known as:

A. Turnaround time
B. Dispatch latency
C. Waiting time
D. Response time

5 In First-Come, First-Served (FCFS) scheduling, if a CPU-bound process holds the CPU for a long time, causing many I/O-bound processes to wait, this phenomenon is called:

A. Starvation
B. Aging
C. Convoy effect
D. Deadlock

6 Which scheduling algorithm is provably optimal for minimizing the average waiting time for a given set of processes?

A. First-Come, First-Served (FCFS)
B. Round Robin (RR)
C. Shortest Job First (SJF)
D. Priority Scheduling

7 In Shortest Job First (SJF) scheduling, how is the next CPU burst length typically predicted?

A. By asking the user
B. By using the length of the previous burst
C. Using exponential averaging of past bursts
D. By random assignment

8 A preemptive version of the Shortest Job First (SJF) algorithm is known as:

A. Shortest Remaining Time First (SRTF)
B. Priority Scheduling
C. Round Robin
D. Multilevel Queue

9 What is the primary problem with Priority Scheduling algorithms?

A. Convoy effect
B. Starvation (Indefinite blocking)
C. High context switch overhead
D. Complex implementation

10 Which technique is used to solve the problem of starvation in Priority Scheduling?

A. Context switching
B. Paging
C. Aging
D. Swapping

11 In Round Robin (RR) scheduling, if the time quantum is extremely large (infinite), the policy behaves like:

A. Shortest Job First (SJF)
B. First-Come, First-Served (FCFS)
C. Priority Scheduling
D. Multilevel Queue

12 If the time quantum in Round Robin scheduling is too small, what is the consequence?

A. Starvation of processes
B. Convoy effect
C. Excessive context switch overhead
D. Reduced I/O utilization

13 Which scheduling algorithm partitions the ready queue into several separate queues, typically with different scheduling algorithms (e.g., Foreground vs. Background)?

A. Round Robin
B. Multilevel Queue Scheduling
C. FCFS
D. SJF

14 What distinguishes Multilevel Feedback Queue scheduling from standard Multilevel Queue scheduling?

A. It uses only one queue.
B. Processes can move between queues.
C. It does not use time quantums.
D. It is strictly non-preemptive.

15 The interval from the time of submission of a process to the time of completion is termed as:

A. Waiting time
B. Response time
C. Turnaround time
D. Throughput

16 Which criteria is most important for an interactive system?

A. Turnaround time
B. Response time
C. Throughput
D. CPU utilization

17 In the exponential averaging formula , what happens if ?

A. The recent history is ignored.
B. The prediction is based only on the last actual CPU burst.
C. The prediction is a constant average.
D. The prediction is always 0.

18 Process execution consists of a cycle of two states. What are they?

A. Ready burst and Waiting burst
B. CPU burst and Memory burst
C. CPU burst and I/O burst
D. Kernel burst and User burst

19 Scheduling under which of the following conditions is considered non-preemptive?

A. When a process switches from running to ready state
B. When a process switches from running to waiting state
C. When a process switches from waiting to ready state
D. When a timer interrupt occurs

20 In Asymmetric Multiprocessing:

A. All processors are peers and run the same scheduler.
B. One master server controls the system, while others look to it for instruction.
C. There is no kernel.
D. Processes are bound to a single processor forever.

21 What is Processor Affinity?

A. The tendency of a process to use a lot of CPU.
B. The preference of a process to stay on the processor it is currently running on.
C. The relationship between parent and child processes.
D. A scheduling algorithm for real-time systems.

22 Which type of processor affinity guarantees that a process will not migrate to another processor?

A. Soft affinity
B. Hard affinity
C. Natural affinity
D. Weak affinity

23 In multiprocessor load balancing, push migration refers to:

A. An idle processor pulling a waiting task from a busy processor.
B. A specific task checking load periodically and moving processes from overloaded to idle processors.
C. The user manually moving processes.
D. The hardware moving threads automatically.

24 A Hard Real-Time System guarantees:

A. Processes will always finish in the shortest time possible.
B. Critical tasks complete on time (before their deadline).
C. Critical tasks get priority over non-critical tasks but may miss deadlines.
D. Throughput is maximized.

25 In Real-Time scheduling, event latency is defined as:

A. The time the CPU spends executing the event handler.
B. The amount of time that elapses from when an event occurs to when it is serviced.
C. The time taken to boot the system.
D. The time interval between two interrupts.

26 Which Real-Time scheduling algorithm assigns priorities statically based on the inverse of the period (shorter period = higher priority)?

A. Earliest Deadline First (EDF)
B. Rate Monotonic Scheduling (RMS)
C. Proportional Share
D. FCFS

27 Which Real-Time scheduling algorithm dynamically assigns priorities based on how close a process is to its deadline?

A. Rate Monotonic Scheduling (RMS)
B. Earliest Deadline First (EDF)
C. Shortest Job First (SJF)
D. Round Robin

28 When scheduling threads, what is Process-Contention Scope (PCS)?

A. Competition for the CPU takes place among all threads in the system.
B. The thread library schedules user-level threads to run on an available LWP (Lightweight Process).
C. The kernel schedules kernel threads onto physical CPUs.
D. The user manually assigns priorities.

29 What is System-Contention Scope (SCS) in thread scheduling?

A. Competition for the CPU takes place among all threads in the system.
B. Threads compete only with threads within the same process.
C. Threads are scheduled strictly by the user.
D. There is no competition; threads run sequentially.

30 In the Many-to-One multithreading model, who handles the scheduling of threads?

A. The Operating System Kernel
B. The Thread Library (User space)
C. The Hardware
D. The Dispatcher

31 Consider 3 processes P1, P2, and P3 with burst times 10, 5, and 2 respectively. They arrive at time 0. What is the Average Waiting Time using FCFS?

A. 17
B. 8.33
C. 5.66
D.

32 Using the same processes (P1=10, P2=5, P3=2) arriving at time 0, what is the Average Waiting Time using SJF (Non-preemptive)?

A. 8.33
B. 2.33
C. 4.5
D. 3

33 Formula for Waiting Time in a non-preemptive system is:

A.
B.
C.
D.

34 Which of the following creates a priority inversion?

A. A high-priority process waiting for a resource held by a low-priority process.
B. A low-priority process interrupting a high-priority process.
C. Two processes with equal priority running simultaneously.
D. The scheduler aging a process too quickly.

35 What is the Priority Inheritance Protocol used for?

A. To assign initial priorities to processes.
B. To solve the priority inversion problem.
C. To calculate the next CPU burst.
D. To manage thread creation.

36 In a Symmetric Multiprocessing (SMP) system:

A. Each processor runs a different operating system.
B. Each processor is self-scheduling.
C. One processor schedules for all others.
D. Processes cannot migrate between processors.

37 Which variable measures the number of processes that complete their execution per time unit?

A. CPU utilization
B. Throughput
C. Turnaround time
D. Response time

38 Under which condition is FCFS generally considered sufficient?

A. In interactive time-sharing systems.
B. In real-time systems.
C. In background batch processing systems.
D. In high-frequency trading systems.

39 What is the overhead associated with Round Robin scheduling that is not present in FCFS?

A. Starvation logic
B. Context Switching
C. Burst prediction
D. Deadlock detection

40 In the context of CPU scheduling, what is Admission Scheduling?

A. The Short-term scheduler selecting a process to run.
B. The Long-term scheduler deciding which processes to admit to the ready queue.
C. The Dispatcher switching context.
D. The Interrupt handler.

41 When is the Shortest Remaining Time First (SRTF) algorithm likely to result in starvation?

A. When short processes keep arriving.
B. When long processes keep arriving.
C. When the time quantum is small.
D. When the system is idle.

42 Little's Law can be applied to queuing systems in OS. The formula is:

A.
B.
C.
D.

43 Which of the following is an example of a Soft Real-Time requirement?

A. Multimedia streaming
B. Pacemaker control
C. Anti-lock braking system
D. Industrial robot arm control

44 Which scheduling algorithm is most difficult to implement in a general-purpose OS because it requires knowing the future?

A. FCFS
B. RR
C. SJF
D. Priority

45 In a Multilevel Feedback Queue, if a process enters the highest priority queue (small quantum) and does not finish within the quantum:

A. It is terminated.
B. It stays in the same queue.
C. It is moved to a lower priority queue.
D. It is moved to a higher priority queue.

46 What is a Gantt Chart used for in Operating Systems?

A. To visualize memory fragmentation.
B. To illustrate the schedule of processes over time.
C. To map logical addresses to physical addresses.
D. To show directory structures.

47 With regard to thread scheduling, what is a Lightweight Process (LWP)?

A. A process that uses very little memory.
B. An intermediate data structure between the user thread and the kernel thread.
C. A thread that has terminated.
D. A hardware interrupt.

48 Which scheduling algorithm combines the benefits of low overhead for short processes and fairness for long processes by using time slicing?

A. Round Robin
B. FCFS
C. SJF
D. LIFO

49 Consider a system where the time quantum for Round Robin is and the context switch time is . To maximize CPU utilization, one should aim for:

A. to be very small compared to
B. to be large enough relative to
C. equal to
D. to be zero

50 Which of the following describes Non-Uniform Memory Access (NUMA) in multiprocessor scheduling?

A. All processors access all memory with equal speed.
B. A processor can access its own local memory faster than memory local to another processor.
C. Memory is not shared between processors.
D. Only the master processor can access memory.