Software
System software, operating systems, interrupts, programming languages, translators and IDEs.
1 System vs Application Software
- Provides services the computer needs to operate
- Manages hardware resources
- Includes: operating systems, utility programs, device drivers
- Examples: Windows, Linux, macOS, antivirus, disk defragmenter
- Provides services the user needs to complete tasks
- Runs on top of the operating system
- Examples: word processor, web browser, spreadsheet, games, photo editor
2 Operating System Functions
An Operating System (OS) is system software that manages the computer's hardware and software resources and provides a platform for applications to run.
| Function | Description |
|---|---|
| Managing files | Organises files in directories, handles read/write operations, manages file permissions |
| Handling interrupts | Receives and prioritises interrupt signals, runs interrupt service routines |
| Providing an interface | GUI (graphical) or CLI (command-line) for user interaction |
| Managing peripherals & drivers | Loads device drivers so hardware (printer, keyboard) works with the OS |
| Managing memory | Allocates RAM to running programs, manages virtual memory |
| Managing multitasking | Allows multiple programs to run concurrently by rapidly switching CPU time |
| Platform for applications | Provides APIs so applications can use hardware without direct access |
| System security | Manages authentication, access control, firewall settings |
| Managing user accounts | Creates/manages user profiles, permissions, and login credentials |
3 Hardware, Firmware & OS Layers
Software runs in layers — each layer depends on the one below it:
Firmware is software permanently stored in ROM on the hardware. The bootloader (firmware) initialises the hardware and loads the OS when the computer starts.
4 Interrupts
An interrupt is a signal sent to the CPU to indicate that an event requires immediate attention. The CPU temporarily pauses its current task to handle the interrupt.
- A device or program generates an interrupt signal
- The CPU finishes its current instruction (not the whole task)
- The CPU saves the current state (registers, program counter) to the stack
- The CPU runs the appropriate Interrupt Service Routine (ISR)
- After the ISR completes, the CPU restores the saved state and resumes the original task
- Generated by physical hardware devices
- Pressing a key on the keyboard
- Moving the mouse
- Printer completing a print job
- Network data arriving
- Generated by running programs
- Division by zero error
- Two processes trying to access the same memory location
- Program requesting OS services (system call)
5 High-Level vs Low-Level Languages
| High-Level Language | Low-Level Language | |
|---|---|---|
| Readability | Uses English-like syntax — easy to read and write | Uses mnemonics or binary — difficult to read |
| Debugging | Easier to debug — code is logical and structured | Harder to debug — must trace binary/mnemonics |
| Machine independence | Platform-independent (write once, run anywhere with right compiler) | Machine-specific — written for one CPU type |
| Hardware control | Cannot directly manipulate hardware | Direct access to hardware registers and memory |
| Speed | Slightly slower after translation | Very fast — executes directly or near-directly |
| Examples | Python, Java, VB.NET, C++ | Assembly language, machine code |
6 Assembly Language
Assembly language is a low-level language that uses mnemonics — short human-readable codes — to represent machine code instructions. An assembler translates assembly language into machine code.
LDA 5 ; Load value from memory address 5 into accumulator ADD 3 ; Add value from address 3 to accumulator STA 10 ; Store result into memory address 10 HLT ; Halt (stop execution)
One assembly instruction corresponds to exactly one machine code instruction. This is unlike high-level languages where one line may produce many machine code instructions.
7 Compilers vs Interpreters
- Translates the entire source code at once
- Produces a standalone executable file
- Program runs faster (pre-translated)
- Error report produced for the whole program after compilation
- Compilation takes time upfront
- Used for the final version of a program
- Translates and executes code line-by-line
- No standalone executable produced
- Slower execution (translates each time)
- Stops at the first error encountered
- Easier to test and debug interactively
- Used during development and testing
A key exam distinction: Compiler = full error report after compiling. Interpreter = stops at first error. Compiler = used for final release. Interpreter = used during development.
8 Integrated Development Environments (IDEs)
An IDE is an application that provides programmers with a complete set of tools for writing, testing, and debugging code in one place.
| Feature | Description |
|---|---|
| Code editor | Text editor with syntax highlighting and formatting for writing code |
| Run-time environment | Allows the program to be executed within the IDE for testing |
| Translator | Built-in compiler or interpreter to translate and run the code |
| Error diagnostics | Highlights syntax errors in real time and shows error messages |
| Auto-completion | Suggests completions for variable names, functions, and keywords as you type |
| Auto-correction | Suggests or applies fixes for common errors automatically |
| Prettyprint | Automatically formats code with correct indentation and spacing for readability |
