Note AcademyNote Academy

Computer Science (AS & A Level) 9618 · Chapter 5

System Software

Why computers need an operating system and what it manages, utility software and program libraries, assemblers, compilers and interpreters, and the features of an IDE.

Written for the 2027–2029 syllabus · 10 min read

System software is the software that runs the computer itself, as opposed to application software that does a job for the user (a word processor or a game). It includes the operating system, utility programs, program libraries and language translators.

5.1 Operating systems

Why a computer needs an operating system

The operating system (OS) is the software that manages the computer's hardware and provides a platform on which application software can run. Without one, every program would have to include its own code to control the keyboard, screen, memory and storage, and the user would have no way to start programs or manage files. The OS hides the complexity of the hardware and provides a user interface.

Key management tasks of an operating system

  • Memory management: allocates main memory to each program, keeps programs from overwriting each other's memory, and frees it when a program ends. If memory is short, it can use virtual memory on the disk (chapter 16).
  • Processor management (scheduling): shares the processor between running programs, so that several appear to run at the same time (multitasking). It decides which process uses the CPU and for how long.
  • File management: organises files and folders on the secondary storage, keeps track of where each file is held, controls access rights (who may read, write or delete), and opens, closes, copies, moves and deletes files.
  • Device management (peripheral management): communicates with each hardware device through its driver, handles input and output, uses buffers and queues (such as the print queue), and deals with interrupts from devices.
  • Security management: controls user accounts, passwords and permissions, and protects data against unauthorised access. It may manage a firewall, and antivirus protection.
  • Error handling: detects and reports faults such as a program crash, a full disk or a device not responding.
  • Providing a user interface, such as a graphical user interface (GUI) or command line.
  • Resource management in general: sharing resources between users and tasks on a multi-user system, and keeping system logs.

Utility software

Utility software carries out maintenance and housekeeping tasks and is usually supplied with the operating system.

UtilityPurpose
Disk formatterPrepares a disk for use by dividing it into tracks and sectors and setting up the file system; erases existing data
Disk defragmenterReorganises files that have been split into pieces (fragments) across the disk so each file is stored in contiguous sectors, which speeds up access on a magnetic hard disk (not needed for SSDs)
Disk content analysis / repair softwareChecks the disk for errors, bad sectors and the amount of space used, and repairs or marks faults
Virus checker (antivirus)Scans files and memory for malware, quarantines or removes it, and keeps its database of known threats updated
File compressionReduces the size of files so they take less space or are sent faster
Backup softwareMakes copies of files, either all of them or only those changed (incremental), so data can be restored after loss or damage
FirewallMonitors incoming and outgoing network traffic and blocks anything that does not meet the rules
Disk clean-upFinds and removes temporary and unnecessary files to free space

Program libraries

A program library is a collection of pre-written, tested routines (functions and procedures) that can be used by any program. Examples are routines for mathematical calculations, sorting, or drawing graphics.

Benefits: saves development time (no need to write the code again), the code has already been tested, so it is reliable, and a programmer can use a routine without needing to understand how it works.

Dynamic link libraries (DLL) are libraries that are loaded into memory only when they are needed, by the running program, rather than being copied into the program's own file. Benefits: the executable file is smaller; a single copy in memory can be shared by several programs at the same time, saving memory; and if the library is updated, all the programs using it get the improvement without being recompiled. Drawbacks: the program will not run if the DLL is missing or the wrong version is installed.

5.2 Language translators

The need for translators

The processor can only execute machine code. A program written in assembly language or in a high-level language must be translated first.

  • An assembler translates an assembly language program into machine code (a one-to-one translation).
  • A compiler translates the whole high-level language program into machine code (object code) in one go. The result is an executable file that can run without the compiler or the source code. Errors are reported after the whole program has been analysed.
  • An interpreter translates and executes a high-level program one statement at a time; it does not produce a separate executable file, and the interpreter must be present each time the program runs. It stops at the first error it finds.

Two lanes: a compiler translates the whole source code once into an executable object code file that then runs fast on its own, while an interpreter reads, translates and runs one statement at a time without making an executable file

Two lanes: a compiler translates the whole source code once into an executable object code file that then runs fast on its own, while an interpreter reads, translates and runs one statement at a time without making an executable file

Compiler or interpreter?

CompilerInterpreter
TranslationWhole program translated onceOne line at a time, each time the program runs
Execution speedFast: already in machine codeSlower: each line is translated every time it runs
OutputA separate executable fileNone
ErrorsReported for the whole program after compilation; can be harder to findReported immediately at the line where it occurs, which makes testing and debugging easier
DistributionCan be distributed as machine code; the source code is hiddenThe user needs the interpreter and the source code
PortabilityThe executable is for one type of processor, and must be recompiled for anotherThe same source runs on any machine that has an interpreter
Best used forThe final, released version of softwareDevelopment and testing; teaching

Partly compiled, partly interpreted

Some languages use both. Java source code is compiled to an intermediate form called bytecode, which is then run by an interpreter (the Java Virtual Machine) on any computer that has one. This gives some of the benefits of both: the bytecode is fast to interpret and the same compiled program runs on different processors. (Chapter 15 covers virtual machines.)

Integrated Development Environments (IDEs)

An IDE is a program that provides the tools a programmer needs in one place. Typical features:

  • Code editor with syntax highlighting (colouring keywords, strings and comments), auto-indentation, context-sensitive prompts (suggestions that fit what is being typed), code completion and pretty-printing (neat layout), and the ability to collapse blocks of code.
  • Error diagnostics: points out syntax errors as you type (dynamic syntax checks) or when you run the program.
  • A compiler or interpreter built in, to run the program from the same window.
  • Debugging tools: single stepping (run one line at a time), breakpoints (stop at a chosen line), watch windows or variable inspection (see the value of variables and expressions as the program runs) and a report window listing them, and a report of the variables and data used.
  • Run-time environment and a graphical user interface builder, with a project manager that keeps all the files of a program together, plus a translator for the language.
  • Version control and testing tools.
Test yourself33 flashcards on this chapter.Flashcards →

Practise this chapter

Every past-paper question on these topics, with the mark scheme.