ALL > Computer and Education > courses > university courses > undergraduate courses > Operating System > ZSTU-(2020-2021)-1 > student homework > 2018529627050_David Bukedi Diela >
Homework2_2018529627050 Version 0
👤 Author: by wx287_oz26ft1wt2_isbggtha4lgepaasa 2020-09-29 05:23:56
A program and a process are related terms. The major difference between program and process is that program is a group of instructions to carry out a specified task whereas the process is a program in execution. While a process is an active entity, a program is considered to be a passive one.

There exist a many-to-one relationship between process and program, which means one program can invoke multiple processes or in other words multiple processes can be a part of the same program.



 

Program purpose:

A Program, in simple words, can be considered as a system activity. In batch processing system these are called executing jobs while in a real-time operating system it is called tasks or programs. A user can run multiple programs where the operating system facilitates its own internal programmed activities such as memory management using some techniques.

 

Process purpose:

A Process is an execution of a program. It is considered as an active entity and realizes the actions specified in a program. Multiple processes can be related to the same program. It handles the operating system activities through PCB (Process control Block) which includes program counter, stack, state etc. Program counter stores the next sequence of instruction that is to be executed later.

 

Key Differences Between Program and Process

A program is a definite group of ordered operations that are to be performed. On the other hand, an instance of a program being executed is a process.

The nature of the program is passive as it does nothing until it gets executed whereas a process is dynamic or active in nature as it is an instance of executing program and perform the specific action.

A program has a longer lifespan because it is stored in the memory until it is not manually deleted while a process has a shorter and limited lifespan because it gets terminated after the completion of the task.

The resource requirement is much higher in case of a process; it could need processing, memory, I/O resources for the successful execution. In contrast, a program just requires memory for storage.

The process status are divided into five states instead of numbers because In a multitasking computer system, processes may occupy a variety of states. These distinct states may not be recognized as such by the operating system kernel.

To incorporate the ideas of tracking the reason for not-running and to represent the creation and termination of processes, we now consider a 5-state model.

Please login to reply. Login

Reversion History

Loading...
No reversions found.