Information Technology Reference
In-Depth Information
Chapter 3
The Programming Interface
From a programmer's point of view, the user is a peripheral that types when you
issue a read request. { Peter Williams
The previous chapter concerned the mechanisms needed in the operating
system kernel to implement the process abstraction. A process is an instance of
a program | the kernel provides an ecient sandbox for executing untrusted
code at user-level, running user code directly on the processor.
This chapter concerns how we choose to use the process abstraction: what
functionality does the operating system provide applications, and what should
go where | what functionality should be put in the operating system kernel,
what should be put into user-level libraries, and how should the operating system
itself be organized?
There are as many answers to this as there are operating systems. Describ-
ing the full programming interface and internal organization for even a single
operating system would take an entire topic. Instead, in this chapter we explore
a subset of the programming interface for UNIX, the foundation of Linux, Mac-
OS, iOS, and Android. We also touch on how the same issues are addressed in
Windows.
First, we need to answer \what" | what functions do we need an operating
system to provide applications?
Process management. Can a program create an instance of another
program? Wait for it to complete? Stop or resume another running pro-
gram? Send it an asynchronous event?
Input/output. How do processes communicate with devices attached
to the computer and through them to the physical world? Can processes
communicate with each other?
101
Search WWH ::




Custom Search