GATE CSE Operating Systems notes
Revise scheduling, virtual memory and synchronization by tracing state changes. These original teaching examples explain the method before you attempt previous year questions.
BEFORE YOU BEGIN
Start with the right foundations
Processes and threads, integer arithmetic, queues and basic C execution.
Original introductory notes with source references. The example is a teaching exercise, rather than an official worked solution to a GATE question. Use the full syllabus to track coverage.
01 · UNDERSTAND
Key concepts
Use these ideas to reason through a question before choosing a formula or an answer.
Scheduling metrics
Turnaround time = completion time − arrival time. Waiting time = turnaround time − CPU burst time for a process with one CPU burst and no I/O. Response time measures the delay until the first CPU allocation; it is distinct from turnaround time.
Virtual memory
Split a virtual address into page number and offset. A page of 2^k bytes uses k offset bits. A page-table lookup maps the page number to a frame; the offset stays unchanged. A TLB miss is not automatically a page fault.
Synchronization and deadlock
A race depends on interleaving shared-memory accesses. Mutual exclusion protects the critical section. The four necessary deadlock conditions are mutual exclusion, hold and wait, no preemption and circular wait; observing one condition alone does not prove deadlock.
02 · WORK THROUGH IT
A worked teaching example
Attempt the problem first, then trace each step and compare your reasoning.
The problem
Two processes arrive at time 0 with CPU bursts of 3 ms and 5 ms. Under non-preemptive FCFS, P1 runs first. Find average waiting and turnaround time; assume zero switching overhead.
Step-by-step reasoning
- 1
P1 occupies [0,3] and P2 occupies [3,8].
- 2
Waiting times are 0 ms and 3 ms, so the mean is (0 + 3)/2.
- 3
Completion times are 3 ms and 8 ms. Since arrivals are 0, these are also turnaround times.
Check your result
Compare your calculation and assumptions.
Average waiting = 1.5 ms; average turnaround = 5.5 ms.
03 · SPOT THE TRAPS
Common mistakes
- Applying the single CPU burst waiting formula to a process with unaccounted I/O.
- Counting a TLB miss as a disk access without checking whether the page is resident.
- Mixing response time and completion time.
04 · CHECK YOUR UNDERSTANDING
Revision checklist
- Draw a scheduling timeline before calculating averages.
- Track page/frame number and byte offset separately.
- List assumptions about arrivals, tie-breaking and overhead.
Explain each point without the notes, then check it with an unfamiliar question. Print or save these notes as a PDF for your revision session.
05 · APPLY IT
Put these ideas into practice
Attempt related previous year questions and record the reasoning behind any mistakes.
Operating System
65 archived questions
Plan your next revision session
Explore topic history or move to another note.
READ FURTHER
Study references
Use the original references for a fuller explanation and more worked problems.