Skip to content

2029–2031 edition · for exams from June 2029. Students sitting exams up to November 2028 follow the current course.

2210 · 04782029–2031 editionPaper 1 · Computer Systems and Logic§5.1, §5.2

5. Software

What the operating system manages — accounts, files, memory, processes, peripherals and interrupts — and how programming languages, translators and IDEs work.

What you need to know212 learning objectives, as printed in the syllabus

  1. 5.1Types of software and interruptsChanged2026–2028 syllabus: §4.1

    Much more on how the operating system manages accounts, files, memory (paging, segmentation), processes, drivers and interrupts.

    Learning objectives (7)
    • 5.1.1Describe the purpose of an operating system as the software layer that manages the system resources that provides a platform for running application software and an interface for users to interact with the computer hardware
    • 5.1.2Describe how an operating system manages user accounts and system security
    • 5.1.3Describe how an operating system manages files, including: (a) file systems; (b) directories
    • 5.1.4Describe how an operating system manages memory, including: (a) allocating memory to processes; (b) loading processes into RAM; (c) paging and segmentation; (d) virtual memory; (e) memory protection
    • 5.1.5Describe how an operating system manages processes, including: (a) scheduling processes; (b) enabling inter-process communication
    • 5.1.6Describe how an operating system manages peripherals and device drivers
    • 5.1.7Describe how an operating system handles interrupts, including: (a) the conditions that cause hardware and software interrupts; (b) how an interrupt is handled with an interrupt service routine (ISR); (c) how the operating system ensures the interrupted process can later resume
  2. 5.2Programming languages, translators and IDEsChanged2026–2028 syllabus: §4.2

    Adds syntax, run-time environment, prettyprint and AI assistance to the IDE list.

    Learning objectives (5)
    • 5.2.1Describe the features of: (a) high-level languages; (b) low-level languages, including assembly language; (c) syntax
    • 5.2.2Explain the advantages and disadvantages of high-level and low-level languages
    • 5.2.3Describe the features and operation of: (a) a compiler; (b) an interpreter; (c) an assembler
    • 5.2.4Explain the advantages and disadvantages of each translator and identify the most appropriate for use in a given scenario
    • 5.2.5Describe the purpose of an integrated development environment (IDE) as a tool to support software development with various functionality provided, including: (a) code editors; (b) run-time environment; (c) translators; (d) error diagnostics; (e) auto-completion / code completion; (f) prettyprint; (g) AI assistance

Objectives quoted from the 2029–2031 syllabus, Version 1, September 2026; © Cambridge University Press & Assessment.

Notes2every learning objective explained, with worked examples

5.1Types of software and interrupts

The operating system (OS) is the software layer between the hardware and everything else. This section explains its jobs — accounts and security, files, memory (including paging, segmentation and virtual memory), processes and peripherals — and how it handles interrupts so the computer can respond to events and then carry on.

The purpose of an operating system

An operating system is the software layer that:

  • manages the system resources — the CPU's time, memory, storage and peripherals;
  • provides a platform for running application software — programs ask the OS for resources instead of controlling the hardware directly;
  • provides an interface so users can interact with the computer hardware (a graphical user interface with windows and icons, or a command-line interface).

User accounts and system security

  • Each user has an account with a username and password (or biometrics), so the OS authenticates who is using the computer.
  • Each account has its own files, settings and permissions / access rights; an administrator account can install software and change settings, standard accounts cannot.
  • The OS can lock an account after too many wrong passwords, and log who signed in.
  • It provides security features such as a firewall, encryption of drives, and installing security updates.

File management

  • A file system is the way the OS organises and keeps track of files on storage: it records where each file's data is stored, its name, size, type, dates and permissions.
  • Directories (folders) group files in a hierarchy (a tree of folders inside folders), so files can be found by a path such as Documents/School/notes.txt.
  • The OS lets users and programs create, open, save, rename, copy, move and delete files and folders, and controls who may read or change each one.

Memory management

  • Allocating memory to processes: the OS decides which part of RAM each running program (process) may use, and frees it when the process ends.
  • Loading processes into RAM: a program must be copied from secondary storage into RAM before the CPU can run it.
  • Paging: memory is divided into fixed-size blocks called pages (and RAM into page frames of the same size). A process's pages can be placed in any free frames, not side by side; a page table records where each page is.
  • Segmentation: memory is divided into variable-size blocks called segments, matching logical parts of a program (e.g. a function, or its data).
  • Virtual memory: when RAM is full, pages not needed now are moved to secondary storage and swapped back when needed (see §2.3).
  • Memory protection: each process may only use its own memory, so one program cannot read or overwrite another's data (or the OS's) — this stops crashes spreading and protects data.

Process management

A process is a program that is running.

  • Scheduling: the CPU can only run one process per core at a time, so the OS decides which process runs next and for how long, switching between them very quickly. This makes several programs appear to run at once (multitasking) and gives important processes priority.
  • Inter-process communication: the OS provides safe ways for processes to share data and send messages to each other (e.g. copy and paste between programs), while keeping their memory separate.

Peripherals and device drivers

  • The OS manages peripherals (printers, keyboards, cameras, storage devices): it sends data to and receives data from them, and handles queues such as print jobs.
  • A device driver is software that lets the OS communicate with a particular hardware device — it translates the OS's general commands into the instructions that device understands.
  • When a new device is connected, the OS loads (or downloads) its driver.

Interrupts and the interrupt service routine

An interrupt is a signal sent to the CPU to say that something needs attention.

Hardware interruptsSoftware interrupts
a key is pressed or the mouse is moveddivision by zero
the printer runs out of paper or inktwo processes trying to use the same memory
data has finished being read from a drivea program requests something from the OS (e.g. to save a file)
a hardware fault; the battery is lowa program error or crash
a timer signal (so the OS can switch process)

How an interrupt is handled:

  1. The CPU checks for interrupts at the end of each fetch–decode–execute cycle.
  2. If there is one, the CPU looks at its priority. If it is more important than the current task, the current task is paused.
  3. The contents of the registers (including the PC) for the current process are saved (on a stack), so it can later resume exactly where it stopped.
  4. The correct interrupt service routine (ISR) — the code that deals with that type of interrupt — is found and run.
  5. When the ISR finishes, the saved register values are restored and the interrupted process carries on.

Exam tips

  • When asked how the OS manages something, give an action the OS takes (allocates, schedules, loads, protects) — not just a definition.
  • Paging = fixed-size pages; segmentation = variable-size, logical segments — this contrast is the usual mark.
  • Give interrupts in matching pairs: cause + hardware/software type.
  • For 'how the process can resume', say the register contents (including the PC) are saved and later restored.

Mistakes that lose marks

  • Saying the OS 'is' the user interface — the interface is one thing it provides.
  • Saying an interrupt stops the computer — it pauses the current task.
  • Calling a device driver a piece of hardware.
  • Mixing up paging (fixed size) and segmentation (variable size).

5.2Programming languages, translators and IDEs

Programs are written in programming languages and then translated into machine code the CPU can run. This section compares high- and low-level languages, explains what syntax is, how compilers, interpreters and assemblers work and when to use each, and the tools an IDE gives a programmer.

High-level and low-level languages; syntax

  • High-level languages (e.g. Python, Java) use English-like words and mathematical notation. One statement often does many machine operations. They are machine independent (portable) and must be translated.
  • Low-level languages relate closely to the CPU's instruction set: machine code (binary instructions the CPU runs directly) and assembly language (short mnemonics such as LDD, ADD, STO for machine code instructions, translated by an assembler).
  • Syntax is the set of rules for how statements must be written in a language (keywords, punctuation, structure). Breaking them is a syntax error and the code will not be translated.
total = price * quantity     # high-level: one line

The same idea in assembly could take several lines: load price, multiply by quantity, store total.

Advantages and disadvantages

High-levelLow-level
Advantageseasier to read, write, understand and debug; quicker to write; portable — runs on different CPUs once translated for them; many built-in functions and librariesdirect control of the hardware (registers, memory); can be faster and use less memory; no high-level translation overhead; good for device drivers and embedded systems
Disadvantagesless direct control of hardware; programs may be larger and slowerhard to write, read and debug; takes longer; machine dependent — only works on that type of CPU

Compiler, interpreter and assembler

CompilerInterpreterAssembler
Translateshigh-level → machine codehigh-level, one statement at a timeassembly → machine code
Howtranslates the whole program in one go into an executable filetranslates and runs each line before moving to the nextconverts each mnemonic into its machine code instruction
Errorsproduces an error report for the whole program after translating; no executable until all are fixedstops at the first error, so it can be fixed and the program run again straight awayreports errors in the assembly code
Running laterthe executable runs without the compiler and without the source codethe interpreter is needed every time the program runsthe machine code runs without the assembler

Choosing a translator

TranslatorAdvantagesDisadvantagesBest when
Compilercompiled program runs fast; can be distributed without the source code (protects it); no translator needed by userserrors only listed after the whole program is compiled; compiling takes time after every changefinished programs are being distributed / sold
Interpretererrors found line by line, easy to debug; changes can be tested immediatelyruns slower (translates every time); users need the interpreter and the source codedeveloping and testing a program; learning to program
Assemblergives fast, small machine code from assemblyonly for that CPU's assembly languagewriting low-level code, e.g. drivers or embedded software

Integrated development environment (IDE)

An IDE is one piece of software with the tools needed to write, translate, test and debug programs.

FeatureHow it helps
Code editorwhere code is typed and edited, often with colour-coded syntax highlighting and line numbers
Run-time environmentlets the program be run inside the IDE to see its output and test it, without leaving the editor
Translatorsa built-in compiler and/or interpreter turns the code into a form that can run
Error diagnosticshighlights and explains errors, shows the line where they happen; debugging tools such as breakpoints, stepping and watching variables
Auto-completion / code completionsuggests the rest of keywords, variable and function names as you type — less typing, fewer spelling mistakes
Prettyprintformats the code automatically — consistent indentation, spacing and colour — so it is easier to read
AI assistancesuggests whole lines or blocks of code, explains code or errors, and helps generate tests; suggestions must still be checked by the programmer because they can be wrong

Exam tips

  • For translator questions compare like with like: how it translates, how it reports errors, and whether it is needed when the program runs.
  • In a 'which translator' scenario use the clue: still developing → interpreter; distributing a finished product → compiler.
  • Low-level: say 'machine dependent' or 'only runs on one type of processor' — a common mark.
  • For each IDE feature explain how it helps the programmer, not just what it is called.

Mistakes that lose marks

  • Saying an interpreter produces an executable file.
  • Saying an assembler translates high-level code.
  • Saying high-level languages are run directly by the CPU.
  • Describing prettyprint as printing the code on paper.

Infographics6download any diagram as PNG or SVG

What the operating system doesThe OS is the layer between the hardware and everything else: it hides complexity and shares resourcesbetween programs.HardwareOperating systemUtility & library softwareApplication softwareUserrequests go down the layers; results come back upOS functionsmemory management (allocate, protect, virtual)process management & multitasking (scheduling)file management (names, folders, access rights)hardware / peripheral management (device drivers)security: user accounts, passwords, access levelsuser interface: GUI (icons, windows) or CLIinterrupt handling; error reportingplatform for running application softwareUtility softwaredisk formatter · defragmenter · backupvirus checker · file compressiondisk contents analysis / repairProgram libraries & DLLsLibrary = pre-written, tested routines you can call.DLL (dynamic link library): loaded only at run timeand shared by many programs → smaller executables,fixes reach every program at once; but a missing orchanged DLL breaks the program.O Level: firmware & bootstrapFirmware in ROM runs first, loads the bootstrap, which loads the OSfrom secondary storage into RAM. Then the OS takes over.Exam wording: “the OS manages …” — name the resource (memory, files, devices, processes, users) and what that involves.cswithzak.com

What the operating system does

O LevelAS
Memory management: paging, segmentation & virtual memoryRAM is shared by many processes. The OS maps each process's logical addresses onto physical frames — ordisk when RAM is full.Process (logical pages)page 0page 1page 2page 3Page tablepageframe05122disk37Physical RAM (frames)frame 0: otherframe 1: otherframe 2: P page 1frame 3: otherframe 4: OSframe 5: P page 0frame 6: otherframe 7: P page 3page 2 (swapped out)Disk — page filepage in on demandPagingMemory and process split into fixed-size pages/frames.Any frame will do → no external fragmentation, butthe last page is partly wasted (internal fragmentation).Pages are physical divisions, invisible to the programmer.SegmentationProcess split into variable-size logical segments (code,stack, data). Segment table holds base + limit. Naturalfor sharing/protection, but leaves gaps between segments(external fragmentation).Virtual memoryOnly the pages in use sit in RAM; the rest live in the page file on disk. A page fault loads the missing page,evicting another (page replacement: FIFO, LRU…). Benefit: programs bigger than RAM, more processes at once.Cost: disk is slow — disk thrashing when the OS spends its time swapping pages in and out instead of running code.“Describe how paging works” = pages, frames, page table, logical → physical mapping, swapped to disk when needed.cswithzak.com

Paging, segmentation & virtual memory

A2
How an interrupt is handledA signal that tells the processor an event needs attention now — without it, the CPU would have to keeppolling every device.SourcesHardwarekey press / mouse clickprinter out of papertimer (time-slice ended)hardware fault, power failureSoftwaredivision by zeroarithmetic overflowillegal / undefined instructiontwo processes need one resource1Device or program raises an interrupt → interrupt flag is set2CPU finishes the current fetch–decode–execute cycle, then tests the flag3Higher priority? Push the registers (PC, ACC, …) onto the stack4Load the ISR (interrupt service routine) address into the PC; run it5Pop the saved registers off the stack; resume the interrupted programPriorities: a low-priority interrupt can itself be interrupted by a higher one (nested); lower ones wait in a queue.The interrupt flag is tested once per cycle — that is why “check for interrupts” is the last step of the FDE cycle.Buffers + interrupts let a slow printer work while the CPU carries on: it interrupts only when its buffer needs refilling.cswithzak.com

How an interrupt is handled

O LevelAS
Compiler · Interpreter · AssemblerAll three are translators: they turn what you wrote into machine code the processor can execute.High-level sourceCompilerExecutable file (then run)High-level sourceInterpreterruns each line (as it goes)Assembly (LDA, ADD…)AssemblerMachine code (one-to-one)CompilerInterpreterTranslateswhole program before it runsone statement at a time, while runningErrorsall listed at the end; nothing runsstops at the first error it meetsSpeedfast — already machine codeslower — translated every runSource needed?no: executable can be distributedyes: source + interpreter every timeBest forfinished software, games, appsdeveloping and debuggingHigh-level: portable, English-like, easy to write and debug. Low-level: direct hardware control, fast, machine-specific.IDE: editor, translator, run-time, debugger (breakpoints, single-step, variable watch), auto-complete, pretty-print.cswithzak.com

Compiler, interpreter & assembler

O LevelAS
What the operating system managesThe OS sits between the hardware and the user's programs. For each job, name the resource and say whatthe OS does with it.User accountslog-in, passwords, accessrights; each user's ownfiles and settingsFile managementfile system: names, folders,create / copy / delete,who may read or writeMemory managementpaging: fixed-size blockssegmentation: variable sizeprotection: no overlapProcess managementmultitasking: schedulinggives each process CPUtime in turnPeripheralsdevice drivers translateOS requests for eachdevice; buffers queue dataInterruptssave current state, runthe ISR, then restoreand resume the taskPaging splits memory and programs into equal pages; segmentation into logical parts of different sizes (code, data).Memory protection stops one process overwriting another's memory — a crash stays inside one program.Also: provides the user interface and runs utility software.cswithzak.com

What the operating system manages

O Level
IDE featuresAn integrated development environment puts the tools for writing, translating, running and debuggingcode in one program.1def average(marks):2 total = 03 for m in marks:4 total = total + m5 return total / len(marks)67print(average([70, 85, 64]))Red dot on line 4 = breakpoint: the program pauses there.Code editortype and edit code, line numbersSyntax highlightingcolours keywords, strings, numbersPrettyprintconsistent indentation and spacingAuto-completionsuggests names as you typeAuto-correctionfixes common typing slipsError diagnosticsshows where and whyRun-time environmentruns the program inside the IDEDebuggerbreakpoints, stepping, watchAI assistancesuggests or explains code — check itTranslator built in: Python is usually interpreted, so errors are reported line by line as it runs.cswithzak.com

IDE features

O Level

Key terms16use these exact words in the exam

operating systemfile systempagingsegmentationmemory protectionschedulingdevice driverinterruptISRhigh-level languageassembly languagecompilerinterpreterassemblerIDEprettyprint

Test yourself

Check you know the 2029–2031 content

Written for the new syllabus only: every card and question traces to a learning objective above. Rounds are random, and marks earn XP on your dashboard.

4 decks · 60 cards · 18 quiz questions.

From the current course

Most of this topic is taught in the 2026–2028 course today. Its notes and past-paper questions still help — skip anything the 2029–2031 syllabus removed (see the notes above).

Enroll nowOnline classes