STUDY GUIDE · GKU 6

Operating systems study guide (Computer Science)

An operating system has two jobs that pull against each other. It must give every program a simple, private machine — its own processor, its own memory, files with names — and it must share one real machine among all of them efficiently and safely. The first half of this unit is about how that is organised: what an OS is for, the layers between an application and the hardware, the boundary between kernel and user mode, and how interrupts and device queues let slow hardware and fast processors work together. The second half is about the hard parts of sharing: processes and threads, the choice of who runs next, what goes wrong when threads touch the same data and how locks and semaphores prevent it, deadlock, how memory is divided and virtualised, and how the OS protects programs and users from each other. Each section opens with a quick-revision card; worked examples run from easy to exam level. The numbers in them were recomputed in Python, the Python listings were run, and the C listings were compiled and run.

Structured by the official ETEC subject standard for this topic: every listed topic and learning outcome, with formulas, figures and worked examples. The full sections are available to members in the app.

SKU 6.1 · Principles of operating systems

  1. Objectives, functions and types of operating systems

    What an operating system is for, the services every one provides, and how batch, time-sharing, single-user, client-server, distributed and real-time systems differ — with the multiprogramming model that explains why sharing the CPU pays.

  2. Logical layers, kernel and user mode, APIs and middleware

    How a system is built in layers, why the processor has a kernel mode and a user mode, how a library call becomes a system call, and what middleware adds between an application and a distributed service.

  3. Resource and process management

    What the OS records about each process, how processes are created with fork, exec and wait, how to measure what an application uses, and the standard ways system software stops wasting CPU and devices: blocking instead of spinning, buffering, spooling and batching.

  4. Interrupt processing

    How an interrupt is taken and returned from, how the source is identified (vectored or polled), how priorities and nesting decide who waits, and when polling beats interrupts.

  5. Device management: drivers, I/O queues and disk scheduling

    How the OS keeps track of devices and the requests waiting for them, what a driver does, how DMA, buffering and spooling relieve the CPU, and how a disk queue is ordered to cut head movement.

SKU 6.2 · Concurrency, scheduling, memory management and OS protection

  1. Process states, threads and context switches

    The states a task passes through and the events that move it, how to design a state diagram for a new problem, and how threads differ from processes — including why user-level threads can stall a whole process.

  2. CPU scheduling algorithms

    The scheduling criteria, the classic algorithms (FCFS, SJF, SRTF, priority, round robin, multilevel feedback) and how to compare them with Gantt charts, turnaround, waiting and response times.

  3. Race conditions, critical sections and locks

    Why concurrent updates go wrong, the three requirements of a critical-section solution, Peterson's algorithm, and the hardware instructions and locks that real systems use.

  4. Semaphores, monitors and the classic synchronisation problems

    Counting and binary semaphores, ordering and signalling with them, monitors and condition variables, and the bounded-buffer, readers–writers and dining-philosophers problems.

  5. Deadlock: conditions, prevention, avoidance and detection

    The four conditions, resource-allocation graphs, the ways to prevent each condition, the Banker's algorithm for avoidance, and detection and recovery.

  6. Memory allocation: partitions, paging and segmentation

    How an OS gives memory to tasks: base and limit registers, contiguous allocation with first, best, worst and next fit, fragmentation, paging and segmentation with their address translations.

  7. Virtual memory: TLB, page faults, replacement and thrashing

    Demand paging, the cost of a TLB miss and of a page fault, the FIFO, LRU and optimal replacement policies with Belady's anomaly, the working set, thrashing, and the cost–performance trade-offs of the memory hierarchy.

  8. Protection and security

    The mechanisms an OS uses to control access — modes, memory protection, protection domains, access matrices, ACLs and capabilities, Unix permissions — the principle of least privilege, authentication, virtualisation as isolation, and what an OS cannot protect against.

MORE COMPUTER SCIENCE GUIDES

All study guides

Read the full guide beside your practice questions.

Open the app