CS414 FA 2006 Assignment 1
None of these questions should be particularly hard, but all will require some thought. Be sure to explain your answers;
be brief, but be clear. Answers should be a few sentences to a
paragraph in length. Remember, we're available if you want to talk
about the assignment; see the office hours on the course website.
-
Which instructions should only be permitted while in kernel mode? Explain with a sentence or two for each.
- Read device registers for a hardware device
- Disable all interrupts
- Perform a trap
- Change the interrupt handler for a given interrupt
- Flush processor caches
- Why is it not safe for the interrupt service routine of an
operating system to use the stack of the current user program
(accessed via the user program's stack pointer) to store temporary
variables?
- Which of these interrupts should have high interrupt priority, and
which should have low priority? [Hint. Consider the expected
latency and bandwidth of each device]
- Disks
- Keyboard
- Mouse
- Network card
- Suppose you're writing a cooperatively multitasked operating
system, and you want control-C to reliably terminate the current
program. Explain how this is possible, or why it isn't.
- Mac OS Classic was Apple's operating system until OS X. It lacked
memory protection: user programs could write to any part of the
address space. Sometimes, when a program crashed, the screen would
show funny colors, and horrible sound would come out of the speakers.
Explain.