Page 49 - DCAP103_Principle of operating system
P. 49
Principles of Operating Systems
Notes Objectives
After studying this unit, you will be able to:
• Discuss process concept
• Explain process control block
• Understand process scheduling
• Explain cooperating processes
• Discuss overview of inter process communication
Introduction
Multiprogramming systems explicitly allow multiple processes to exist at any given time, where
only one is using the CPU at any given moment, while the remaining processes are performing
I/O or are waiting.
The process manager is of the four major parts of the operating system. It implements the process
abstraction. It does this by creating a model for the way the process uses CPU and any system
resources. Much of the complexity of the operating system stems from the need for multiple
processes to share the hardware at the same time. As a conseuence of this goal, the process
manager implements CPU sharing (called scheduling), process synchronization mechanisms,
and a deadlock strategy. In addition, the process manager implements part of the operating
system’s protection and security.
2.1 Process Concept
One impediment to our discussion of operating systems is the question of what to call all
the CPU activities. A batch system executes jobs, whereas a timeshared system has user
programs, or tasks. Even on a single-user system, such as Microsoft Windows and Macintosh
OS, a user may be able to run several programs at one time: a word processor, web browser,
and e-mail package.
Even if the user can execute only one program at a time, the operating system may need to
support its own internal programmed activities, such as memory management. In many respects,
all these activities are similar, so we call all of them processes. The terms job and process are
used almost interchangeably in this text. Although we personally prefer the term process, much
of operating-system theory and terminology was developed during a time when the major
activity of operating systems was job processing. It would be misleading to avoid the use of
commonly accepted terms that include the word job (such as job scheduling) simply because
process has superseded job.
2.1.1 Process
A process is a sequential program in execution. The components of a process are the following:
• The object program to be executed (called the program text in UNIX).
• The data on which the program will execute (obtained from a file or interactively from
the process’s user).
• Resources required by the program (for example, files containing requisite information).
• The status of the process’s execution.
42 LOVELY PROFESSIONAL UNIVERSITY