- An operating system acts as an intermediary between the user of a computer and the computer hardware.
- The purpose of an operating system is to provide an environment in which a user can execute programs in a convenient and efficient manner.
- An operating system is software that manages the computer hardware.
- The hardware must provide appropriate mechanisms to ensure the correct operation of the computer system and to prevent user programs from interfering with the proper operation of the system.
- Internally, operating systems vary greatly in their makeup, since they are organized along many different lines.
- The design of a new operating system is a major task.
- It is important that the goals of the system be well defined before the design begins.
- These goals form the basis for choices among various algorithms and strategies.
- Because an operating system is large and complex, it must be created piece by piece.
- Each of these pieces should be a well delineated portion of the system, with carefully defined inputs, outputs, and functions.
Operating System is a program that manages the computer hardware.
also provides a basis for application programs and acts as an intermediary between
the computer user and the computer hardware.
amazing aspect of operating systems is how varied they are in accomplishing
operating systems are designed primarily to optimize utilization of hardware.
Personal computer (PC) operating systems support complex games, business
applications, and everything in between.
systems for handheld computers are designed to provide an environment in which
a user can easily interface with the computer to execute programs.
some operating systems are designed to be convenient, others to be efficient,
and others some combination of the two.
we can explore the details of computer system operation, we need to know
something about system structure.
begin by discussing the basic functions of system startup, I/0, and storage.
also describe the basic computer architecture that makes it possible to write a
functional operating system.
modern computer system consists of one or more processors, some main memory, disks,
printers, a keyboard, a display, network interfaces, and other input/output
in all, a complex system. Writing programs that keep track of all these
components and use them correctly, let alone optimally, is an extremely
this reason, computers are equipped with a layer of software called the operating
system, whose job is to manage all these devices and provide user programs
with a simpler interface to the hardware.
placement of the operating system is shown in Fig. 1.
the bottom is the hardware, which, in many cases, is itself composed of two or
more levels (or layers).
- The lowest level contains physical devices, consisting of integrated circuit chips, wires, power supplies, cathode ray tubes, and similar physical devices.
comes the microarchitecture level, in which the physical devices are
grouped together to form functional units.
this level contains some registers internal to the CPU (Central Processing
Unit) and a data path containing an arithmetic logic unit.
each clock cycle, one or two operands are fetched from the registers and
combined in the arithmetic logic unit (for example, by addition or Boolean
result is stored in one or more registers.
some machines, the operation of the data path is controlled by software, called
- On other machines, it is controlled directly by hardware circuits.
Figure 1.1 A computer system consists of hardware, system
programs, and application programs.
purpose of the data path is to execute some set of instructions. Some of these
can be carried out in one data path cycle; others may require multiple data
instructions may use registers or other hardware facilities.
the hardware and instructions visible to an assembly language programmer form
the ISA (Instruction Set Architecture) level.
level is often called machine language.
machine language typically has between 50 and 300 instructions, mostly for
moving data around the machine, doing arithmetic, and comparing values.
this level, the input/output devices are controlled by loading values into
special device registers.
example, a disk can be commanded to read by loading the values of the disk
address, main memory address, byte count, and direction (read or write) into
practice, many more parameters are needed, and the status returned by the drive
after an operation is highly complex.
for many I/O (Input/output) devices, timing plays an important role in the
hide this complexity, an operating system is provided.
consists of a layer of software that (partially) hides the hardware and gives
the programmer a more convenient set of instructions to work with.
example, read block from file is conceptually simpler than having to worry
about the details of moving disk heads, waiting for them to settle down, and so
top of the operating system is the rest of the system software.
we find the command interpreter (shell), window systems, compilers, editors,
and similar application-independent programs.
is important to realize that these programs are definitely not part of the
operating system, even though they are typically supplied by the computer
is a crucial, but subtle, point. The operating system is (usually) that portion
of the software that runs in kernel mode or supervisor mode.
is protected from user tampering by the hardware (ignoring for the moment some
older or low-end microprocessors that do not have hardware protection at all).
and editors run in user mode.
a user does not like a particular compiler, he is free to write his own if he
so chooses: he is not free to write his own clock interrupt handler, which is
part of the operating system and is normally protected by hardware against attempts
by users to modify it.
distinction, however, is sometimes blurred in embedded systems (which may not
have kernel mode) or interpreted systems (such as Java-based operating systems
that use interpretation, not hardware, to separate the components).
for traditional computers, the operating system is what runs in kernel mode.
said, in many systems there are programs that run in user mode but which help
the operating system or perform privileged functions.
example, there is often a program that allows users to change their passwords.
program is not part of the operating system and does not run in kernel mode,
but it clearly carries out a sensitive function and has to be protected in a
some systems, this idea is carried to an extreme form, and pieces of what is
traditionally considered to be the operating system (such as the file system)
run in user space.
such systems, it is difficult to draw a clear boundary.
running in kernel mode is clearly part of the operating system, but some
programs running outside it are arguably also part of it, or at least closely
associated with it.
above the system programs come the application programs.
programs are purchased or written by the users to solve their particular
problems, such as word processing, spreadsheets, engineering calculations, or
storing information in a database.
- MODERN OPERATING SYSTEMS by Andrew S. Tanenbaum, Second Edition
- The Operating System Concepts by Silberschatz, Galvin, Gagne, 8th Edition