CSE 221: Homework 1
Winter 2006
Due: Thursday, February 9, 2006 at the start of class (3:30pm)
Answer the following questions. For questions asking for short
answers, support your answers with material from the referenced
papers, or with your own critical arguments, as appropriate. I am
interested in your justifications as much as the answer itself. There
may not necessarily be a "right" answer, although some answers may be
easier to justify. Finally, do not use shorthand -- write your
answers using complete sentences.
- A fundamental aspect of protection in operating systems is rights
amplification. Rights amplifications enables a more privileged
protection domain to perform an operation on behalf of a less
privileged protection domain in a control fashion while maintaining
protection in the system.
For each of the following operating systems, state (a) the
protection domains that they support, (b) the mechanism for crossing
protection domains, (c) how rights are represented, (d) how rights are
amplified crossing domains, and (e) how the OS determines whether to
allow the domain crossing.
- Butler Lampson once gave a set of design
principles for computer systems. One of the principles he gave was to
use hints to speed up normal execution. He noted:
A hint, like a cache entry, is the saved result of some
computation. It is different in two ways: it may be wrong, and it
is not necessarily reached by an associative lookup. Because a hint
may be wrong, there must be a way to check its correctness before
taking any unrecoverable action. It is checked against the "truth",
information that must be correct but can be optimized for this
purpose rather than for efficient execution. Like a cache entry,
the purpose of a hint is to make the system run faster. Usually
this means that it must be correct nearly all the time.
Give an example of the use of a hint drawn from one of the papers
we have covered in the class. Explain what information comprises a
hint, and how it is checked against the "truth". Give, to the best
of your ability, an estimate of the performance gain obtained by using
the hint, and describe how the hint is correct "nearly all the
time".
- Pilot made a strong argument for tailoring the design and
implementation of operating systems to personal computers. We have
also seen commercial operating systems like MSDOS and MacOS tailored
towards personal computers as well. Why do you think we still run
multi-user timesharing systems like Unix on our PCs? (Note: Consider,
for example, the requirements we have of the systems that we use
today.)
- Operating systems go to great lengths to provide isolation and
protection among processes executing on the system. Process
debugging, however, represents a necessary, interesting feature that
is made more difficult by process isolation and protection, and
requires support from the operating system to function correctly.
To the extent possible and where appropriate, when answering the
following questions support your answers with approaches for debugging
support found in the papers you have read to this point (e.g., Tenex,
Pilot, Lampson Protection).
- Why must a traditional operating system like Unix explicitly
provide support for process debugging?
- List two distinct operations that a debugger must perform that
require support from the operating system.
- Because processes are protected and isolated from each
other, operating systems must also provide support for communication
and coordination among processes. Why can't debuggers just use the
support that operating systems already provide for process
communication and coordination?
- Do language runtime environments like Java and Perl require
operating system support for debugging programs in those languages?
Why or why not?
- When working on an operating system, developers also need
to use a debugger on the operating system itself. Why is debugging
the kernel of an operating system more challenging than debugging a
user-level process? What is one option for where to run a kernel
debugger?