Explain the life cycle of a process, Computer Engineering

Assignment Help:

Explain the life cycle of a process

Each procedure has a life cycle, which consists of execution, creation and termination phases of the procedure.  A method may create several new procedures, which in turn may also generate still new processes, using system calls. In UNIX operating system environment, a new procedure is produced by fork system call. Process creation needs the following four actions:

i) Setting up the process description: Setting up the process description needs the creation of a Process Control Block (PCB). A  Process Control Block contains basic data such as owner, process identification number, process status, explanation of the allocated address space and other completion dependent process specific information needed for procedure management.

ii)   Allocating an address space:  There are only  two ways to allocate address space to processes; allocating separate space to each process or distribution the address space among the created processes.

iii) loading the program into the allocated address space: The executable program file is overloaded into the allocated memory space.

iv)  Passing the process description to the process scheduler:  The process created is then conceded to the process scheduler who distributes the processor to the competing processes.

The process implementation phase is controlled by the process scheduler. Process scheduling may be per process or per thread. The process scheduling involves three concepts: process states, state transition diagram and scheduling policy.

A process may be in one of the following states given below:

  • New: The process is being formed.
  • Running: The process is being implemented on a single or multiple processors.
  • Waiting: The process is to come for some event to occur.
  • Ready: The process is prepared to be implemented if a processor is available.
  • Terminated: The process has completed execution.

At any time a procedure may be in any single of the above said states. As soon as the process is announce into the job line, it goes into equipped state. When the process scheduler transmits the process, its state turn into running. When the process is completely implemented then it is completed and we say that it is in the completed state. However, the process may return to ready state due to some type of interruption or may go to in waiting state because of some I/O activity. When I/O activity is finished it may go to ready state. The state transition diagram shown in figure 3:

                                2250_life cycle of a process.png

The scheduling policy may be both non pre-emptive and pre-emptive. In pre-emptive policy, the process may be distructed. OS had dissimilar scheduling policies. One of the common policies is First In First Out (FIFO) to select the process to be implemented. When the process finished implementation it is terminated by system calls like abort.


Related Discussions:- Explain the life cycle of a process

Write a program to event advertised, A museum has a collection of old poste...

A museum has a collection of old posters advertising events of various kinds (theatre, sport, fairs, lectures etc.). It wishes to keep a record of these, containing, for each poste

Minimization of the logic function using NORgates, Minimize the logic funct...

Minimize the logic function F(A, B, C, D) = ∑ m(1,3,5,8,9,11,15) + d(2,13) using NOR gates with help of K-map. Ans. Realization of given expression by using NOR gates: In POS

Discuss the advantages of firewalls, Discuss the advantages of Firewalls ...

Discuss the advantages of Firewalls Firewalls also offer additional protection to local users who like to browse or surf out from the Intranet to the Internet, by acting as pro

Postpurchase interaction, Postpurchase Interaction Customer service an...

Postpurchase Interaction Customer service and support: The considerations at this stage can be explained by the following example: Consider a bundle having of a portfolio

Why is the wait-for-memory-function-completed, Why is the Wait-For-Memory-F...

Why is the Wait-For-Memory-Function-Completed step required when reading from or writing to the main memory? WMFC step is needed for the write control signal / read control si

What are the various hazards encountered in pipelining, What is pipelining?...

What is pipelining? What are the various hazards encountered in pipelining?  Explain in detail. The major characteristics of a pipeline are: a) Pipelining cannot be exe

Uninformed search strategies - artificial intelligence, Uninformed Search S...

Uninformed Search Strategies: To be able to undertake an unaware search, there is really important that the entire agent needs to know is the primary state, then the possible

Fuzzy logic - artificial intelligence, Fuzzy Logic: In the logics we a...

Fuzzy Logic: In the logics we are here described above, what we have been concerned with truth: whether propositions and sentences are true. Moreover, with some natural langua

What is compact disk rom, Q. What is Compact Disk ROM? Both audio CD an...

Q. What is Compact Disk ROM? Both audio CD and CD-ROM (compact disk read-only memory) share similar technology. Main difference is that CD-ROM players are more rugged and have

Difference between perl and mod_perl, Perl is a language and MOD_PERL is a ...

Perl is a language and MOD_PERL is a module of Apache used to increase the performance of the application.

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd