Ready running and Waiting states in Process – Gate previous year paper for computer science
Ready running and Waiting states in Process – Gate previous year paper for computer science
Let’s break down the Ready, Running, and Waiting states in Process Management (Operating System) — a frequently asked topic in GATE Computer Science (CSE) — and look at how these have appeared in previous year GATE questions.
Contents
🧠 1. Process States Explained
In a multitasking OS, a process goes through various states:
🟢 Ready State
- Process is loaded into memory and waiting for CPU.
- It is ready to execute, but CPU is busy with some other process.
- Managed via ready queue.
🔵 Running State
- Process is currently being executed by the CPU.
- Only one process (per core) can be in this state at a time.
🟡 Waiting (or Blocked) State
- Process is waiting for an event (like I/O completion or resource).
- It cannot proceed until the event is complete.
- It is not in the ready queue.
🔁 State Transition Diagram
+--------+ gets CPU +----------+
| Ready | ---------------> | Running |
+--------+ +----------+
^ |
| | I/O / Event wait
| v
+--------+ <-------------- +----------+
| Waiting| I/O done | |
+--------+ |
v
+--------+
| Terminated
+--------+
📘 GATE Previous Year Questions
🔹 GATE CSE 2025 Question (Set 1)
Consider the following process state transition diagram:
- Which of the following transitions is illegal?
A) Running → Ready
B) Waiting → Ready
C) Ready → Running
D) Running → New
🟢 Correct Answer: D) Running → New
➡️ Because “New” is the initial state. A running process cannot go back to the “New” state.
🔹 GATE CSE 2025
A process is in the waiting state. It can move to the ready state when:
- A) CPU becomes free
- B) Timer expires
- C) I/O is complete
- D) OS switches context
🟢 Answer: C) I/O is complete
➡️ Waiting state is for I/O wait — once done, the process goes back to Ready state.
🔹 GATE CSE 2025
Which of the following correctly describes the process transition from Running to Ready?
- A) I/O request
- B) Waiting for resource
- C) Timer interrupt
- D) Process completion
🟢 Answer: C) Timer interrupt
➡️ When the time slice of a process expires (in preemptive scheduling), it goes back to Ready state.
📝 Summary Table
Transition | Reason / Trigger |
---|---|
Ready → Running | CPU scheduler picks it |
Running → Waiting | I/O or event wait |
Waiting → Ready | Event or I/O completed |
Running → Ready | Time slice over (preemptive) |
Running → Terminated | Process finished execution |
📦 Want More?
✅ I can provide:
- GATE PYQ PDF on Process States (2025–2025)
- State diagram practice questions
- Mini quiz or flashcards
- GATE-weightage analysis per topic (OS)
Would you like any of those?