States of the Process
Let’s go through the stages of the process that comes in its lifecycle. This will help in understanding semaphores.
- Running: It states the Process in execution.
- Ready: It states that the process wants to run.
- Idle: The process runs when no processes are running
- Blocked: The processes are not ready and not a candidate for a running process. It can be awakened by some external actions.
- Inactive: The initial state of the process. The process is activated at some point and becomes ready.
- Complete: When a process executes its final statement.
Semaphores and its types
Semaphores are compound data types with two fields one is a Non-negative integer S.V. and the second is a set of processes in a queue S.L. It is used to solve critical section problems, and by using two atomic operations, it will be solved. In this, wait and signal that is used for process synchronization.
Contact Us