| | |
Summary: 6
Mechanism: Limited Direct Execution
In order to virtualize the CPU, the operating system needs to
somehow share the physical CPU among many jobs running
seemingly at the same time. The basic idea is simple: run one
process for a little while, then run another one, and so forth. By
time sharing the CPU in this manner, virtualization is achieved.
There are a few challenges, however, in building such virtu-
alization machinery. The first is performance: how can we imple-
ment virtualization without adding excessive overhead to the
system? The second is control: how can we run processes effi-
ciently while retaining control over the CPU? Control is particu-
larly important to the OS, as it is in charge of resources; without
it, a process could simply run forever and take over the machine,
or access information that it shouldn't be allowed to access. At-
taining performance while maintaining control is thus one of
the central challenges in building an OS.
THE CRUX:
HOW TO EFFICIENTLY VIRTUALIZE THE CPU WITH CONTROL
The OS must virtualize the CPU in an efficient manner, but
|