0% found this document useful (0 votes)
8 views

Chapter 4 As

Chapter 4 discusses processor management, including the roles of the Job Scheduler and Process Scheduler in managing job states and CPU allocation. It covers various scheduling algorithms, such as First-Come, First-Served and Shortest Job Next, and their implications on system performance. Additionally, it highlights concepts like context switching, aging, and the importance of managing both CPU-bound and I/O-bound jobs.

Uploaded by

caobadan122003
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
8 views

Chapter 4 As

Chapter 4 discusses processor management, including the roles of the Job Scheduler and Process Scheduler in managing job states and CPU allocation. It covers various scheduling algorithms, such as First-Come, First-Served and Shortest Job Next, and their implications on system performance. Additionally, it highlights concepts like context switching, aging, and the importance of managing both CPU-bound and I/O-bound jobs.

Uploaded by

caobadan122003
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 6

Chapter 4: Processor Management

TRUE/FALSE

1. A process is an inactive unit, such as a file stored on a disk.

ANS: F PTS: 1 REF: 112

2. A program is an active entity that requires a set of resources, including a processor and special
registers, to perform its function.

ANS: F PTS: 1 REF: 112

3. The processor is also known as the CPU.

ANS: T PTS: 1 REF: 112

4. A single processor can be shared by several jobs, or several processes, but if, and only if, the operating
system has a scheduling policy, as well as a scheduling algorithm, to determine when to stop working
on one job and proceed to another.

ANS: T PTS: 1 REF: 113

5. The Processor Manager is a composite of two submanagers: one in charge of job scheduling and the
other in charge of program scheduling.

ANS: F PTS: 1 REF: 114

6. After a job has been placed on the READY queue by the Job Scheduler, the Process Scheduler takes
over.

ANS: T PTS: 1 REF: 114

7. Most computer programs alternate between CPU cycles and I/O cycles.

ANS: T PTS: 1 REF: 115

8. CPU-bound jobs (such as printing a series of documents) have many brief CPU cycles and long I/O
cycles

ANS: F PTS: 1 REF: 115

9. As a job moves through the system it’s always in one of five states; these are called the job status or
the process status.

ANS: T PTS: 1 REF: 116

10. From HOLD, the job moves to WAITING when it’s ready to run but is waiting for the CPU.

ANS: F PTS: 1 REF: 117


11. The transition from one job or process status to another is initiated by either the Job Scheduler or the
Process Scheduler.

ANS: T PTS: 1 REF: 117

12. Each job is uniquely identified by the user’s identification and a pointer connecting it to its descriptor.

ANS: T PTS: 1 REF: 118

13. The process state contains all of the data about the job needed by the operating system to manage the
processing of the job.

ANS: F PTS: 1 REF: 119

14. It is possible to minimize response time by running only interactive jobs and letting the batch jobs wait
until the interactive load ceases.

ANS: T PTS: 1 REF: 120

15. The Process Scheduler often uses a timing mechanism and periodically interrupts running processes
when a predetermined slice of time has expired.

ANS: T PTS: 1 REF: 121

16. First-come, first-served (FCFS) is a preemptive scheduling algorithm that handles jobs according to
their arrival time.

ANS: F PTS: 1 REF: 122

17. If one job monopolizes the system, the extent of its overall effect on system performance depends on
the scheduling policy and whether the job is CPU-bound or I/O-bound.

ANS: T PTS: 1 REF: 123

18. Shortest job next (SJN) is a nonpreemptive scheduling algorithm (also known as shortest job first, or
SJF) that handles jobs based on the length of their CPU cycle time.

ANS: T PTS: 1 REF: 124

19. When using priority scheduling, priorities are assigned to jobs by the owner of the job (the user).

ANS: F PTS: 1 REF: 125

20. The Shortest remaining time (SRT) algorithm is often used in interactive systems.

ANS: F PTS: 1 REF: 126

21. Context switching is required by all preemptive algorithms.

ANS: T PTS: 1 REF: 127

22. In round robin scheduling, if processing isn’t finished when time expires, the job is preempted and put
at the end of the READY queue and its information is saved in its PCB.
ANS: T PTS: 1 REF: 128

23. Multiple-level queues isn’t really a separate scheduling algorithm but works in conjunction with
several other schemes.

ANS: T PTS: 1 REF: 130

24. Aging is used to ensure that jobs in lower-level queues will eventually complete their execution.

ANS: T PTS: 1 REF: 132

25. The control program that handles the interruption sequence of events is called the interrupt scheduler.

ANS: F PTS: 1 REF: 133

MULTIPLE CHOICE

1. What is the name for a portion of a process that can run independently?
a. thread c. miniprocess
b. program d. subprocess
ANS: A PTS: 1 REF: 112

2. What is the high-level scheduler?


a. Process Scheduler c. Program Scheduler
b. Job Scheduler d. Thread Scheduler
ANS: B PTS: 1 REF: 114

3. What does the Job Scheduler seek to do when scheduling jobs?


a. run all CPU intensive jobs first c. balance CPU and I/O intensive jobs
b. run all I/O intensive jobs first d. run the quickest jobs first
ANS: C PTS: 1 REF: 114

4. The Process Scheduler assigns the CPU to execute the processes of those jobs placed on the ____
queue by the Job Scheduler.
a. waiting c. process
b. next d. ready
ANS: D PTS: 1 REF: 115

5. In a highly interactive environment there is a third layer of the Processor Manager called the ____
scheduler.
a. Managing c. middle-level
b. Subprocess d. Program
ANS: C PTS: 1 REF: 115

6. What is the initial state for a job?


a. HOLD c. WAITING
b. RUNNING d. READY
ANS: A PTS: 1 REF: 116
7. Which transition is managed by the Job Scheduler?
a. READY to RUNNING c. RUNNING back to READY
b. RUNNING to WAITING d. HOLD to READY
ANS: D PTS: 1 REF: 117

8. Which transition is sometimes managed by the Process Scheduler and sometimes by the Job
Scheduler?
a. WAITING to READY c. RUNNING to FINISHED
b. RUNNING to WAITING d. HOLD to READY
ANS: C PTS: 1 REF: 117

9. Which of the following is part of the Process State information maintained in the PCB?
a. Main Memory c. Process Priority
b. Register Contents d. All of the above
ANS: D PTS: 1 REF: 118

10. Which section of the PCB is used primarily for performance measurement?
a. Accounting c. Process Identification
b. Process State d. Process Status
ANS: A PTS: 1 REF: 119

11. The queues used to manage jobs are formed from ____.
a. jobs c. PCBs
b. processes d. record identifiers
ANS: C PTS: 1 REF: 119

12. An I/O request is called a(n) ____ wait in multiprogramming environments.


a. forced c. scheduled
b. natural d. indirect
ANS: B PTS: 1 REF: 121

13. How is the First-come, first-served (FCFS) scheduling algorithm implemented?


a. using a FIFO queue c. using a circular queue
b. using a LIFO queue d. using a directed graph
ANS: A PTS: 1 REF: 122

14. What is a disadvantage of First Come First Served?


a. I/O-bound jobs are given priority
b. jobs are frequently interrupted
c. CPU-bound jobs are given priority
d. average turnaround times vary widely and are seldom minimized
ANS: D PTS: 1 REF: 123

15. Assume that four jobs A-D require the CPU cycles listed below. Using the SJN algorithm, which job
is run first?

Job: ABCD
CPU cycle: 5 2 6 4
a. A c. C
b. B d. D
ANS: B PTS: 1 REF: 124

16. Assume that four jobs A-D require the CPU cycles listed below. Using the SJN algorithm, what is the
average turnaround time?

Job: ABCD
CPU cycle: 5 2 6 4
a. 5.5 c. 9.0
b. 6.8 d. 11.1
ANS: C PTS: 1 REF: 124

17. Some systems increase the priority of jobs that have been in the system for an unusually long time to
expedite their exit. This is known as ____.
a. lagging c. bumping
b. aging d. accelerated priority
ANS: B PTS: 1 REF: 126

18. Assume that jobs A-D arrive in the ready queue in quick succession and have the CPU cycle
requirements listed below. Using the SRT algorithm, what is the average turnaround time?

Arrival time: 0 1 2 3
Job: ABCD
CPU cycle: 6 3 1 4
a. 2.5 c. 7.75
b. 6.25 d. 9.0
ANS: B PTS: 1 REF: 126

19. Assume jobs A-D arrive in quick succession in the READY queue. Using round robin scheduling,
what is the turnaround time for job C?

Arrival time: 0 1 2 3
Job: ABCD
CPU cycle: 8 4 9 5
a. 7 c. 22
b. 20 d. 24
ANS: D PTS: 1 REF: 128-129

20. What is the best time quantum size in round robin scheduling?
a. it depends on the system
b. it should be long enough to allow 80 percent of the CPU cycles to run to completion
c. it should be at least 100 times longer than the time required to perform one context switch
operation
d. All of the above
ANS: D PTS: 1 REF: 130

21. No movement between queues is a very simple policy that rewards those who have ____ jobs.
a. high-priority c. CPU-bound
b. low-priority d. I/O-bound
ANS: A PTS: 1 REF: 131

22. Which multiple-level queue management scheme facilitates I/O-bound jobs and is good in interactive
systems?
a. No movement between queues c. Variable time quantum per queue
b. Movement between queues d. Aging
ANS: B PTS: 1 REF: 131-132

23. Which multiple-level queue management scheme allows for faster turnaround of CPU-bound jobs?
a. No movement between queues c. Variable time quantum per queue
b. Movement between queues d. Aging
ANS: C PTS: 1 REF: 132

24. When the operating system detects a nonrecoverable error, which of the following happens first?
a. state of the interrupted process is saved c. interrupt is processed
b. type of interrupt is described and stored d. processor resumes operation
ANS: B PTS: 1 REF: 133

25. What is another name for an internal interrupt?


a. I/O interrupt c. illegal operation
b. illegal job instruction d. synchronous interrupt
ANS: D PTS: 1 REF: 133

You might also like