Operating Systems/Process and Thread

From Wikiversity
Jump to: navigation, search

Contents

[edit] Process Life Cycle

Like in real world a process too is created and destroyed. Different operating systems have different life cycles for the processes but a very general life cycle model is given below.

[edit] Dormant

A dormant stage of the process is actually a program, executable file on hard disk.

[edit] Fork

A process is said to be forked when loaded in the main memory. The execution of instructions may not start immediately. The keyword fork is basically a Unix UNIX terminology.

[edit] Ready

A process is said to be ready when it can start executing the very next moment. Many times a process may need some resource which is not available for that time. Processes which can be scheduled to run at any time by a scheduler is said to be in ready state.

[edit] Blocked

A said to be blocked when it is waiting for some interrupt to occur. Without its occurrence it can not continue. Such processes are not considered by the scheduler for scheduling.

[edit] Running

The process which is currently being executed by the processor is called the running process. In an uniprocessor system there exist only one running process at a time.

[edit] Dead

A process is said to be dead or killed when its execution is complete. Such processes are then removed from the memory of a computer. A process might end for the following reasons.

  • It performed all the functions it was supposed to perform and ended normally
  • It created some exception and was killed by operating system
  • The parent of the process is killed.
Personal tools
Namespaces

Variants
Actions
Navigation
Community
Toolbox
Wikimedia projects
Print/export