Midterm #1 (Spring 2002)
CPU Scheduling (20 points)
Explain why Round-Robin scheduling tends to favor CPU bound
processes over I/O bound ones.
CPU scheduling quanta have remained about the same over the
past 20 years, but processors are now over 1,000 times faster. Why haven’t CPU
scheduling quanta changed?
List 4 events that might occur to cause the kernel to context
switch from one user process to another.
(10 points) Explain
how a process differs from a thread.
(20 points) Given a system that provides binary semaphores
(semaphores whose values is either 0 or 1).
Show the code to implement counting semaphores using binary semaphores.
(15 Points) Deadlock
List the four necessary conditions for deadlock
Explain how the Resource-Request (Banker’s) algorithm prevents
(20 points) Project
After you setup a user mode process, do you still need the
stack created for kernel mode threads?
Explain your answer.
What would happen if your _Entry function in libuser.a returns
rather than calling Exit.
Explain the difference between policy and mechanism in an
operating system. Given an example of
One of the usability goals for an operating system is
“proportionality.” Explain what is meant by this term.