The CPU and the fetch-execute cycle
The CPU (Central Processing Unit) carries out instructions from programs, following the fetch-decode-execute cycle non-stop while the computer is on.
- Fetch: the next instruction address is held in the Program Counter (PC); it is copied into the Memory Address Register (MAR), fetched from memory and placed in the Memory Data Register (MDR).
- Decode: the Control Unit works out what the instruction means.
- Execute: the instruction is carried out, often using the Arithmetic Logic Unit (ALU) for maths/logic, with results held briefly in registers like the Accumulator.
Common mistake: mixing up MAR (holds an address) and MDR (holds the actual data/instruction).
Von Neumann architecture
Most computers use Von Neumann architecture: one memory stores both data and instructions, and they travel along shared buses (address bus, data bus, control bus). The system clock generates pulses that pace the fetch-execute cycle.
CPU performance
Three main factors affect CPU performance:
- Clock speed: measured in GHz (billions of cycles per second); higher means more fetch-execute cycles per second.
- Number of cores: more cores can process more instructions in parallel, but only if software is written to use them.
- Cache size: a small, very fast memory on the CPU itself that stores frequently used data/instructions, cutting down slow trips to RAM.
Common mistake: assuming clock speed alone determines speed — cache and cores matter just as much, and software must be optimised to benefit.
Embedded systems
An embedded system is a computer built into a larger device to perform one specific, dedicated task (e.g. a washing machine controller, a satnav, a microwave). They are usually cheap, small, and have limited processing power compared to general-purpose computers.
Memory: RAM vs ROM
- RAM (Random Access Memory): volatile (loses contents when powered off), stores currently running programs and data, can be read from and written to.
- ROM (Read Only Memory): non-volatile, stores the BIOS/bootstrap program that starts the computer, cannot normally be written to.
Common mistake: saying RAM is 'permanent storage' — RAM is temporary and volatile; only secondary storage and ROM keep data without power.
Secondary storage
Secondary storage is non-volatile and holds data/software long-term when the computer is off. Three types with trade-offs on capacity, speed, portability and durability:
- Magnetic (e.g. hard disk drives): large capacity, cheap per GB, but slower and has moving parts that can fail.
- Optical (e.g. DVD, Blu-ray): cheap, portable, but lower capacity and can scratch.
- Solid state (e.g. SSD, USB flash): fast, durable (no moving parts), more expensive per GB.
Units and data storage
Data is stored in bits (0 or 1); 8 bits = 1 byte. Storage scales in these approximate steps: 1000 bytes = 1 kilobyte, 1000 KB = 1 megabyte, 1000 MB = 1 gigabyte, 1000 GB = 1 terabyte. Know how to compare file sizes and storage capacity, and calculate how many files fit in a given space.
What are the three stages of the fetch-execute cycle?
Fetch, decode, execute.
tap to reveal
What does the Program Counter (PC) store?
The memory address of the next instruction to be fetched.
tap to reveal
What is the difference between the MAR and the MDR?
The MAR holds a memory address; the MDR holds the actual data or instruction found at that address.
tap to reveal
What is Von Neumann architecture?
An architecture where data and instructions share the same memory and are transferred along common buses (address, data, control).
tap to reveal
Name the three main factors affecting CPU performance.
Clock speed, number of cores, and cache size.
tap to reveal
What does clock speed measure and in what unit?
How many fetch-execute cycles the CPU can perform per second, measured in GHz (gigahertz).
tap to reveal
Why doesn't doubling the number of cores always double performance?
Because software must be specifically written to make use of multiple cores running in parallel.
tap to reveal
What is cache and why does it speed up the CPU?
A small, very fast memory on the CPU that stores frequently used data/instructions, avoiding slower trips to RAM.
tap to reveal
What is the key difference between RAM and ROM?
RAM is volatile (loses data when powered off) and holds running programs; ROM is non-volatile and holds the bootstrap/BIOS program.
tap to reveal
Define an embedded system and give an example.
A computer built into a larger device to perform one specific dedicated task, e.g. a microwave controller or satnav.
tap to reveal
Name the three types of secondary storage.
Magnetic, optical, and solid state.
tap to reveal
Why is solid state storage often preferred despite costing more per GB?
It is faster and more durable because it has no moving parts, unlike magnetic storage.
tap to reveal
How many bits make one byte?
8 bits = 1 byte.
tap to reveal
Put these in order from smallest to largest: megabyte, byte, gigabyte, kilobyte, terabyte.
Byte, kilobyte, megabyte, gigabyte, terabyte.
tap to reveal
What is the role of the ALU?
The Arithmetic Logic Unit performs all arithmetic and logical operations during the execute stage.
tap to reveal