

Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!


CHAPTER 11
Applied Computing Study Notes • Resource Management, Processes & Scheduling
An Operating System (OS) acts as the essential bridge between physical hardware and user software. Its primary job is to share scarce hardware resources fairly, securely, and efficiently across competing programs.
Kernel Mode vs. User Mode: Hardware enforces dual-mode execution. User apps run in restricted User Mode and must request privileged hardware actions via System Calls into the OS kernel. Interrupt-Driven Design: Hardware timers and I/O devices raise interrupts to pause running code, letting the OS regain control and respond immediately to events.
A Process is an active program instance with its own isolated virtual memory space. A Thread is a lightweight execution path inside a process that shares heap memory and open files with sibling threads.
Figure 11.1: Standard Process Lifecycle State Transitions
Scheduling Policy How It Selects Tasks^ Primary Trade-off Round Robin (RR )
Gives each ready task an equal fixed time slice (quantum) in a circular queue.
Great interactive responsiveness; high context-switch overhead if quantum is too small. Shortest Job First
Runs the task with the smallest predicted CPU burst next.
Minimizes average wait time, but long tasks risk starvation.
Priority Preemptive
Immediately interrupts lower-priority work when a critical task arrives.
Essential for real-time systems; requires priority aging to prevent starvation.
Paging & Translation: Virtual addresses split into fixed-size pages mapped to physical RAM frames via page tables, allowing programs to exceed physical RAM using disk swap space. Race Conditions & Mutexes: When threads read/write shared state concurrently without coordination, results become unpredictable. A Mutex (Mutual Exclusion Lock) ensures only one thread enters a critical section at a time.
NEW READY RUNNING EXIT WAITING (I/O)
Exam Checklist: Four Necessary Conditions for Deadlock
Deadlock occurs only when all four hold simultaneously: (1) Mutual Exclusion on resources, (2) Hold and Wait while requesting more, (3) No Preemption of held locks, and (4) Circular Wait chain among threads. Breaking any one condition prevents deadlock.