Tuesday, February 20, 2018

Draw a State Diagram of Process and explain it in detail.

A state diagram shows the behavior of classes in response to external stimuli. Specifically a state diagram describes the behavior of a single object in response to a series of events in a system. Sometimes it's also known as a Harel state chart or a state machine diagram. This UML diagram models the dynamic flow of control from state to state of a particular object within a system.

  • New state : Initially process will be in New state . It means process is under creation or process is being created .
  • Ready state : Once the process is created it will be moved on to ready state . In the ready state there will be multiple number of process .
  • Running state : One of the process will be selected from the ready state and dispatched on to the running state .When the process in the running state it occupied the CPU and executing the instruction of the process and performing CPU time .In the running state one process at any point of the time .
  • Wait or Block state : If the running process required any input output then it will come to wait state .In the wait state there will be multiple number of process .It means multiple process will perform input output operation simultaneously .
  • Suspended Ready : If the resources are not sufficient to maintain the process in the ready state the some of the process will suspended and they will be moved on to suspended ready state . If the process in the suspended ready state it is reside in the backing store (Secondary memory) .
  • Suspend wait or Block state : If the resources are not sufficient to maintain the process in the wait or block state then some of the process (Low priority) will be suspended and they will be moved to the suspended waiting or block state. In this process is reside in the backing store 

Mahendra Nyaupane 

No comments:

Post a Comment

History of computer generations