Inside the Machine

You use computers every day — your phone, your laptop, your games console, even the self-checkout at Tesco. But have you ever wondered what is actually happening inside these devices? How does tapping an icon on a screen cause a video to play, a message to send, or a game to load?

In this topic, you will learn about the physical components (hardware) that make up a computer system, how the CPU processes instructions at incredible speed, where data is stored, and the software that ties it all together. Understanding how computers work “under the hood” will make you a better programmer and help you make smarter decisions about the technology you use.

This topic covers:

The Central Processing Unit (CPU)

The CPU (Central Processing Unit) is the “brain” of the computer. It carries out all the processing — performing calculations, making decisions, and controlling everything else in the system. Modern CPUs are tiny silicon chips, yet they can perform billions of operations per second.

Key Components of the CPU

ALU (Arithmetic Logic Unit)

This is where the actual calculations happen. The ALU performs:

Think of the ALU as the “maths department” of the CPU.

CU (Control Unit)

The control unit is the “manager” — it coordinates all the activities of the CPU. It:

Registers

Registers are tiny, ultra-fast storage locations inside the CPU itself. They hold the data and instructions the CPU is currently working on. Key registers include:

Cache

Cache is a small amount of very fast memory built into or very close to the CPU. It stores copies of frequently used data and instructions so the CPU does not have to fetch them from the slower main memory (RAM) every time. There are usually multiple levels: L1 (smallest, fastest), L2, and L3 (largest, slowest of the three, but still much faster than RAM).

Key Concept: The Fetch-Decode-Execute (FDE) Cycle Every instruction the CPU runs goes through three stages, repeated billions of times per second:

1. Fetch: The CPU reads the next instruction from memory (the address is in the Program Counter). The PC is then incremented to point to the following instruction.
2. Decode: The Control Unit works out what the instruction means and what operation is needed.
3. Execute: The instruction is carried out — this might involve the ALU doing a calculation, data being moved, or a result being stored.

This cycle repeats continuously until the program ends or the computer is turned off.

The FDE Cycle: A Detailed Walkthrough

Let us trace through a specific example. Imagine the CPU needs to execute the instruction “LOAD the value stored at memory address 100 into the Accumulator”. Here is exactly what happens at each stage:

Stage 1: Fetch

  1. The Program Counter (PC) holds the address of the next instruction — let us say it currently holds address 42.
  2. The address in the PC (42) is copied into the Memory Address Register (MAR).
  3. The CPU sends this address along the address bus to memory, and a “read” signal is sent along the control bus.
  4. The instruction stored at address 42 (e.g. LOAD 100) is sent back along the data bus into the Memory Data Register (MDR).
  5. The PC is incremented to 43, so it now points to the next instruction.

Stage 2: Decode

  1. The instruction in the MDR (LOAD 100) is passed to the Control Unit.
  2. The CU decodes it and determines: “This is a LOAD instruction. I need to read the data from memory address 100 and place it into the Accumulator.”

Stage 3: Execute

  1. The address 100 is placed into the MAR.
  2. A “read” signal is sent along the control bus. The value at address 100 travels along the data bus into the MDR.
  3. The value from the MDR is copied into the Accumulator (ACC).
  4. The instruction is complete. The CPU loops back to the Fetch stage and reads the instruction at address 43.

Now imagine the next instruction is ADD 101 (add the value at address 101 to the accumulator). The same three stages repeat: fetch the instruction, decode it, then execute it by reading address 101 and sending both values to the ALU, which adds them and stores the result in the ACC.

Did You Know? The first electronic general-purpose computer, ENIAC (1945), weighed 30 tonnes and filled an entire room. It had less processing power than a modern pocket calculator. Today, the CPU in your smartphone can perform billions of calculations per second and fits on a chip smaller than your thumbnail.

The System Bus

The CPU, memory, and other components communicate using a set of wires called the system bus. It has three parts:

BusWhat It CarriesDirection
Address Bus The address of the memory location or I/O device being accessed One-way: CPU → memory/devices
Data Bus The actual data or instructions being transferred Two-way: CPU ↔ memory/devices
Control Bus Control signals (e.g. read, write, clock pulse, interrupt) Two-way: CPU ↔ memory/devices

The width of the address bus determines how many memory locations the CPU can address (e.g. a 32-bit address bus can access 232 = roughly 4 billion addresses). The width of the data bus determines how much data can be transferred in a single operation.

Von Neumann Architecture

Most modern computers follow the Von Neumann architecture, proposed by mathematician John von Neumann in 1945. The key idea is that both instructions and data are stored together in the same memory. The architecture consists of:

Von Neumann Architecture — Simplified Diagram Description Imagine the following layout:

At the centre is the CPU, which contains the CU (Control Unit), the ALU (Arithmetic Logic Unit), and Registers (PC, MAR, MDR, ACC).

To the right of the CPU is Main Memory (RAM and ROM), storing both programs and data.

Below the CPU are Input Devices (e.g. keyboard, mouse) on the left and Output Devices (e.g. monitor, printer) on the right.

All components are connected by three buses running between them: the Address Bus, the Data Bus, and the Control Bus — together forming the System Bus.

The crucial feature: instructions and data share the same memory and the same bus, meaning the CPU cannot fetch an instruction and read data at the exact same time (this is known as the “Von Neumann bottleneck”).

What Makes a CPU Faster?

FactorWhat It IsHow It Helps
Clock speed The number of FDE cycles per second, measured in GHz Higher clock speed = more instructions processed per second. A 3.5 GHz CPU does 3.5 billion cycles per second.
Number of cores A core is an independent processing unit within the CPU More cores = more tasks can be processed simultaneously (parallel processing). A quad-core CPU can handle 4 tasks at once.
Cache size The amount of fast memory built into the CPU More cache = more frequently used data is kept close, reducing the need to access slower RAM.
Common Mistake: Students often say “more cores always makes a computer faster.” This is not always true. Software must be designed to use multiple cores (parallelisation). A single-threaded program running on 8 cores will not be faster than on 1 core — it can only use one at a time.
Did You Know? Modern CPUs contain billions of transistors, each one smaller than a virus. The Apple M2 chip, for example, has over 20 billion transistors on a piece of silicon roughly the size of a postage stamp. Each transistor acts as a tiny electronic switch that can be either on (1) or off (0), forming the basis of all digital computing.

Key Topics in Detail

Memory: RAM and ROM

RAM (Random Access Memory)

Think of RAM as your desk: it holds everything you are currently working on. The bigger your desk, the more things you can have open at once.

ROM (Read-Only Memory)

Think of ROM as a permanent instruction manual built into the computer that tells it how to start up.

Virtual Memory

When RAM is full, the operating system uses a section of the hard drive/SSD as temporary extra memory. This is called virtual memory. It prevents the computer from crashing when RAM runs out, but it is much slower than real RAM because secondary storage is slower than memory. If your computer starts to feel sluggish when lots of programs are open, virtual memory is often the reason.

Key Concept: RAM vs ROM RAM is volatile (loses data when power is off), read/write, and stores currently running programs. ROM is non-volatile (keeps data without power), read-only, and stores the boot-up instructions. Do not confuse RAM with storage — RAM is temporary working memory, while storage (HDD/SSD) is for permanent files.

Secondary Storage

Secondary storage keeps data permanently, even when the computer is switched off. There are several types:

Magnetic Storage (HDD — Hard Disk Drive)

Solid State Storage (SSD — Solid State Drive)

Optical Storage (CD, DVD, Blu-ray)

USB Flash Drives

Cloud Storage

FeatureHDDSSDOpticalUSB Flash
SpeedModerateFastSlowModerate
CapacityVery highHighLowModerate
Cost per GBLowMediumVery lowMedium-High
DurabilityFragile (moving parts)RobustEasily scratchedRobust (but easy to lose)
PortabilityModerateHighHighVery high

Storage Capacity in Real-World Terms

It can be hard to visualise what storage sizes actually mean. Here are some rough comparisons using everyday files:

StoragePhotos (12 MP)Songs (MP3)HD Films (1080p)
1 GB~250 photos~250 songsLess than 1 film
32 GB (USB stick)~8,000 photos~8,000 songs~8 films
256 GB (SSD)~64,000 photos~64,000 songs~64 films
1 TB (HDD)~250,000 photos~250,000 songs~250 films
4 TB (large HDD)~1,000,000 photos~1,000,000 songs~1,000 films

When Should You Use Each Type of Storage?

ScenarioBest ChoiceWhy
A student needs to carry homework between home and school USB flash drive Small, portable, cheap, and easy to plug in anywhere
A school needs fast-booting computers for everyday use SSD Very fast read/write speeds mean the operating system and applications load quickly
A business needs to archive 10 years of records cheaply HDD (or cloud storage) HDDs offer very high capacity at low cost per GB; cloud offers off-site backup
A musician wants to distribute a demo album to fans Optical disc (CD) or cloud CDs are cheap to produce in bulk; cloud links are free to share
A photographer needs to back up 500 GB of RAW images on the go Portable SSD Fast transfer speeds, durable (no moving parts), compact enough for a camera bag

Embedded Systems

An embedded system is a dedicated computer system designed to perform one specific function (or a small set of functions) within a larger mechanical or electrical device. Unlike the general-purpose computer on your desk, an embedded system is built into the product and usually cannot be reprogrammed by the user.

Examples of embedded systems:

Embedded Systems vs General-Purpose Computers

FeatureEmbedded SystemGeneral-Purpose Computer
PurposeSingle dedicated taskMany different tasks
User interfaceSimple or none (buttons, small screen)Full GUI, keyboard, mouse, monitor
Operating systemMinimal or none (firmware)Full OS (Windows, macOS, Linux)
Reprogrammable?Usually not by the userYes — install any software
Processing powerLow (only what is needed)High (to handle many tasks)
CostVery low per unitHigher
ExamplesWashing machine, traffic light, fitness trackerLaptop, desktop PC, tablet
Key Concept: Embedded Systems Embedded systems are everywhere. There are far more embedded processors in the world than general-purpose computers. Your home alone might contain dozens: in the fridge, the boiler, the TV remote, the smoke alarm, and even in your toothbrush if it is electric. They are designed to be cheap, reliable, and energy-efficient because they only need to do one job well.

Operating Systems

An operating system (OS) is system software that manages the computer’s hardware and provides a platform for application software to run. Examples include Windows, macOS, Linux, Android, and iOS.

The OS handles:

Utility Software

Utility software performs specific maintenance or housekeeping tasks to keep the computer running smoothly:

Types of Backup

Backup software can create copies in different ways, each with trade-offs:

Backup TypeWhat It DoesAdvantagesDisadvantages
Full Backup Copies all files every time Simple to restore — everything is in one place Slow and uses the most storage space; time-consuming for large systems
Incremental Backup Copies only files that have changed since the last backup (of any type) Fast and uses minimal storage Slower to restore — you need the last full backup plus every incremental backup since
Differential Backup Copies all files that have changed since the last full backup Faster to restore than incremental — only need the last full backup plus the latest differential Uses more storage than incremental; gets larger over time until the next full backup

High-Level vs Low-Level Languages

FeatureHigh-Level LanguageLow-Level Language
ExamplesPython, Java, C#, JavaScriptAssembly language, Machine code
ReadabilityEasy to read and write (close to English)Difficult to read (cryptic codes/binary)
PortabilityWorks on different types of hardwareSpecific to one type of CPU
TranslationMust be translated (compiled/interpreted)Assembly needs an assembler; machine code runs directly
SpeedSlower to execute (needs translation)Faster (closer to what the CPU understands)
Use casesMost software developmentDevice drivers, embedded systems, performance-critical code

Compilers vs Interpreters

High-level code must be translated into machine code before the CPU can execute it. There are two main approaches:

Compiler

Interpreter

Key Concept: Compiler vs Interpreter A compiler translates all the code at once and produces a standalone executable — fast execution, but errors are reported all together. An interpreter translates one line at a time — slower execution, but errors are caught immediately, making development easier. Python uses an interpreter, which is one reason it is so beginner-friendly.
Common Mistake: Students sometimes say “Python is compiled” or “C++ is interpreted.” While some languages can technically use both methods, in exams you should say Python is interpreted and C/C++ are compiled. Also, do not confuse translation methods with the language itself — a compiler/interpreter is a separate piece of software, not a feature of the language.

Real-World Case Studies

Case Study 1: How a Smartphone Uses All the Components

A modern smartphone is a remarkable example of computer systems working together:

  • CPU — A multi-core processor (e.g. Apple A17, Snapdragon 8 Gen 3) handles everything from running apps to rendering graphics. It uses the FDE cycle billions of times per second.
  • RAM — Typically 6–12 GB. Keeps your currently open apps in memory so you can switch between them instantly. When you close an app, its data is cleared from RAM.
  • Storage — 64 GB to 1 TB of flash storage (similar technology to SSDs) stores your photos, apps, music, and the operating system itself.
  • Operating System — iOS or Android manages all the hardware, handles multitasking (switching between apps), manages touch input, and provides the app store for installing software.
  • Sensors — Accelerometer (detects movement/orientation), GPS (location), gyroscope (rotation), proximity sensor (detects when the phone is near your ear), fingerprint sensor, and camera sensors — all controlled by embedded systems within the phone.
  • Embedded systems — The phone contains many embedded processors: one manages the touchscreen, another handles the Bluetooth chip, another runs the camera’s image processing, and the baseband processor manages mobile network connections.
Case Study 2: Games Console vs PC

A games console (like a PlayStation 5 or Xbox Series X) and a gaming PC both play games, but they are designed very differently:

  • Hardware — A console uses custom-designed hardware. Every PS5 has the exact same CPU, GPU, RAM, and SSD. This means game developers know exactly what hardware their game will run on and can optimise perfectly for it. A PC, on the other hand, can have thousands of different hardware combinations.
  • Operating system — Consoles run a stripped-down, optimised OS that dedicates almost all system resources to the game. A gaming PC runs a full operating system (Windows) with background processes, updates, and other software competing for resources.
  • Performance — Because console hardware is fixed and the OS is lean, a console can often deliver a smooth gaming experience with hardware that would be considered mid-range in a PC. However, PCs can be upgraded with more powerful components over time.
  • Flexibility — A PC is a general-purpose computer: you can browse the web, write documents, develop software, and play games. A console is more like a specialised system — its primary function is gaming and media playback.
Case Study 3: Moore’s Law — The Incredible Shrinking Transistor

In 1965, Gordon Moore (co-founder of Intel) observed that the number of transistors on a microchip was doubling approximately every two years, while the cost per transistor was halving. This observation became known as Moore’s Law.

  • 1971 — The Intel 4004 (the first commercial microprocessor) had 2,300 transistors.
  • 1989 — The Intel 486 had 1.2 million transistors.
  • 2005 — Dual-core processors arrived with hundreds of millions of transistors.
  • 2020s — Modern chips like the Apple M2 Ultra contain over 130 billion transistors.

However, Moore’s Law is slowing down. Transistors are now so small (just a few nanometres — smaller than a strand of DNA) that we are approaching the physical limits of silicon. Engineers face challenges with heat dissipation, quantum effects, and the sheer difficulty of manufacturing at such tiny scales. The industry is exploring new approaches including 3D chip stacking, new materials, and even quantum computing to continue improving performance.

Did You Know? The Apollo 11 guidance computer that helped land humans on the Moon in 1969 had just 74 KB of memory and ran at 0.043 MHz. That is less memory than a single email attachment today, and millions of times slower than the phone in your pocket. Yet it successfully navigated a spacecraft 384,000 km to the Moon and back.

Key Vocabulary

Make sure you know all of these terms. They frequently appear in exam questions.

TermDefinition
CPUCentral Processing Unit — the “brain” of the computer that processes instructions and performs calculations.
ALUArithmetic Logic Unit — the part of the CPU that performs arithmetic (add, subtract, etc.) and logic (comparisons, AND/OR/NOT) operations.
CUControl Unit — the part of the CPU that fetches, decodes, and coordinates the execution of instructions.
RegisterA tiny, ultra-fast storage location inside the CPU used to hold data or instructions the CPU is currently processing.
PCProgram Counter — a register that holds the memory address of the next instruction to be fetched.
MARMemory Address Register — holds the address of the memory location currently being read from or written to.
MDRMemory Data Register — holds the data that has been fetched from memory or is about to be written to memory.
ACCAccumulator — a register that holds the result of the most recent calculation performed by the ALU.
CacheA small amount of very fast memory inside or near the CPU that stores frequently accessed data and instructions.
Clock SpeedThe number of FDE cycles the CPU can perform per second, measured in gigahertz (GHz).
CoreAn independent processing unit within the CPU. Multiple cores allow parallel processing of tasks.
FDE CycleFetch-Decode-Execute cycle — the three-stage process the CPU repeats to carry out each instruction.
RAMRandom Access Memory — volatile, read/write memory that stores currently running programs and data.
ROMRead-Only Memory — non-volatile memory that stores permanent boot-up instructions (BIOS/UEFI).
Virtual MemoryA section of the hard drive/SSD used as temporary extra RAM when physical RAM is full.
HDDHard Disk Drive — magnetic secondary storage using spinning platters. High capacity, low cost, but slower and fragile.
SSDSolid State Drive — flash-based secondary storage with no moving parts. Fast, durable, but more expensive per GB.
OpticalStorage media (CD, DVD, Blu-ray) that use a laser to read and write data. Low capacity but cheap and portable.
Embedded SystemA dedicated computer system built into a larger device to perform a specific function (e.g. washing machine controller).
Operating SystemSystem software that manages hardware resources, provides a user interface, and runs application software (e.g. Windows, Android).
Utility SoftwareSystem software that performs maintenance tasks such as antivirus scanning, defragmentation, encryption, and backup.
CompilerA translator that converts the entire high-level source code into machine code in one go, producing a standalone executable.
InterpreterA translator that converts and executes high-level source code one line at a time. Requires the interpreter to be present each time.
High-Level LanguageA programming language close to human language (e.g. Python, Java). Portable and easy to read, but must be translated.
Low-Level LanguageA programming language close to machine code (assembly language or binary). Hard to read but fast and hardware-specific.
Machine CodeBinary instructions (0s and 1s) that the CPU can execute directly. The lowest level of programming language.
Assembly LanguageA low-level language using short mnemonics (e.g. LDA, ADD, STO) that map directly to machine code instructions. Translated by an assembler.

Exam Tips

Exam Tip: Registers and the FDE Cycle

Know your registers and what each one stores. Be able to name the PC, MAR, MDR, and ACC and explain each one’s role. In the exam, you may be asked to trace through the FDE cycle for a given instruction — practise writing out each step, naming the registers and buses used at each point. Use the walkthrough example in this topic as a model answer.

Exam Tip: Comparing Storage Types

When comparing storage types (HDD vs SSD vs optical vs USB), always structure your answer around specific advantages and disadvantages: speed, capacity, cost, durability, and portability. If the question gives a scenario (e.g. “a photographer who travels frequently”), link your answer directly to the needs of that person. Do not just list generic facts — explain why a particular storage type suits the scenario.

Exam Tip: Always Give Examples

Whenever possible, support your answers with specific examples. Instead of writing “an embedded system is in a household device,” write “an embedded system is used in a washing machine to control the wash cycle, water temperature, and spin speed.” Specific examples demonstrate deeper understanding and earn more marks.

Exam Tip: Compilers vs Interpreters

This is one of the most commonly examined topics. Remember the key trade-off: a compiler is slow to translate but produces fast-running code; an interpreter is quick to start running but slower overall because it translates every time. Be able to name an example of each (e.g. C is compiled, Python is interpreted).

Test Yourself

Click on each question to reveal the answer. Try to answer in your head first!

Q1: Name the three stages of the fetch-decode-execute cycle and briefly explain each.

Answer: Fetch: The next instruction is retrieved from memory using the address in the Program Counter (PC), and the PC is incremented. Decode: The Control Unit interprets the instruction to determine what operation is required. Execute: The instruction is carried out, which may involve the ALU performing a calculation, data being transferred, or a result being stored.

Q2: What is the role of the ALU in the CPU?

Answer: The ALU (Arithmetic Logic Unit) performs all arithmetic operations (addition, subtraction, multiplication, division) and logic operations (comparisons such as greater than, less than, equal to, and Boolean operations like AND, OR, NOT). It is the part of the CPU where actual calculations take place.

Q3: Name three factors that affect CPU performance and explain how each one helps.

Answer: 1. Clock speed — Measured in GHz; a higher clock speed means more fetch-decode-execute cycles per second, so more instructions are processed. 2. Number of cores — More cores allow multiple instructions to be processed in parallel (at the same time). 3. Cache size — A larger cache stores more frequently used data close to the CPU, reducing the time spent fetching data from slower RAM.

Q4: What is the difference between RAM and ROM?

Answer: RAM is volatile (loses data when power is off), can be read from and written to, and stores programs and data currently in use. ROM is non-volatile (retains data without power), is read-only, and stores the BIOS/UEFI boot-up instructions. RAM is much larger than ROM and changes constantly during use.

Q5: Explain what virtual memory is and give one disadvantage of using it.

Answer: Virtual memory is a section of the hard drive or SSD that the operating system uses as temporary extra RAM when physical RAM is full. It prevents the computer from crashing when too many programs are open. Disadvantage: Virtual memory is much slower than real RAM because secondary storage has slower read/write speeds, causing the computer to slow down noticeably (sometimes called “thrashing”).

Q6: Compare SSDs and HDDs. Give two advantages of each.

Answer: SSD advantages: (1) Much faster read/write speeds, so programs load quicker. (2) More durable because there are no moving parts, making them better for portable devices. HDD advantages: (1) Lower cost per gigabyte, making them cheaper for storing large amounts of data. (2) Available in very high capacities (up to 20+ TB), good for bulk storage and backups.

Q7: Name four functions of an operating system.

Answer: Any four from: (1) Memory management — allocating RAM to programs. (2) File management — organising files and controlling access. (3) User interface — providing a way for users to interact with the computer. (4) Peripheral management — communicating with external devices via drivers. (5) Multitasking — running multiple programs by switching between them rapidly. (6) Security — managing user accounts and access permissions.

Q8: What is defragmentation, and why is it not needed for SSDs?

Answer: Defragmentation reorganises files on an HDD so that each file’s data is stored in consecutive blocks rather than scattered across the disk. This improves read speed because the read/write head does not have to jump around. It is not needed for SSDs because SSDs have no moving read head — they can access any location equally quickly regardless of where the data is stored. In fact, defragmenting an SSD can reduce its lifespan by causing unnecessary write operations.

Q9: Give two advantages of using a high-level programming language over a low-level language.

Answer: (1) Easier to read, write, and debug — High-level languages use English-like syntax, making them more accessible to programmers. (2) Portable — High-level code can run on different types of hardware (with appropriate translation), whereas low-level code is written for a specific CPU architecture and cannot be easily transferred to another system.

Q10: What is the difference between a compiler and an interpreter? Give one advantage of each.

Answer: A compiler translates the entire source code into machine code all at once, producing a standalone executable file. Advantage: The compiled program runs faster because it does not need translating again each time. An interpreter translates and executes the code one line at a time. Advantage: It stops at the first error and tells you exactly where it is, making it easier to find and fix bugs during development.

Q11: What is an embedded system? Give two examples.

Answer: An embedded system is a dedicated computer system designed to perform a specific function within a larger device. It is usually built into the product and cannot be reprogrammed by the user. Example 1: A washing machine uses an embedded system to control the wash cycle, water temperature, and drum speed. Example 2: A car engine management system uses an embedded processor to monitor sensors and adjust fuel injection and ignition timing in real time.

Q12: Describe the role of each of the three buses in the Von Neumann architecture.

Answer: Address bus — carries the memory address of the location being read from or written to. It is one-directional (CPU to memory). Data bus — carries the actual data or instructions being transferred between the CPU and memory (or I/O devices). It is bidirectional. Control bus — carries control signals such as read/write commands, clock pulses, and interrupt requests. It is bidirectional and coordinates the timing and actions of all components.

Q13: A school needs to buy new computers. Recommend whether they should have HDDs or SSDs. Justify your answer.

Answer: The school should choose SSDs. Justification: (1) SSDs are much faster, so the computers will boot up quickly and applications will load without delay — this is important in a school where lesson time is limited. (2) SSDs have no moving parts, making them more durable — school computers are often handled roughly by students, so durability matters. (3) SSDs are quieter and produce less heat, creating a better classroom environment. The higher cost per GB is acceptable because school computers typically do not need huge storage capacities — most student work can be saved on the school network or cloud storage.

Q14: Explain why Python programs run slower than equivalent C programs.

Answer: Python is an interpreted language, meaning the Python interpreter translates and executes the code one line at a time, every time the program is run. This repeated translation adds overhead. C is a compiled language — the C compiler translates the entire source code into machine code once, producing a standalone executable that the CPU runs directly without any further translation. Because the compiled C program is already in machine code, it executes much faster. Additionally, C gives programmers more direct control over memory and hardware, allowing further optimisation.

Q15: Describe what happens during the fetch stage of the FDE cycle, naming the registers used.

Answer: During the fetch stage: (1) The address of the next instruction is held in the Program Counter (PC). (2) This address is copied from the PC into the Memory Address Register (MAR). (3) The address is sent along the address bus to main memory, and a read signal is sent along the control bus. (4) The instruction stored at that memory address is retrieved and sent along the data bus into the Memory Data Register (MDR). (5) The PC is incremented by one so that it now points to the next instruction in sequence.

Past Paper Questions

Practise these exam-style questions. Click each question to reveal the mark scheme.

Describe the purpose of the CPU and name its three main components. 3 marks

Mark scheme:

  • The CPU processes instructions / carries out calculations and makes decisions (1 mark)
  • ALU (Arithmetic Logic Unit) — performs arithmetic and logic operations (1 mark)
  • CU (Control Unit) — fetches, decodes and coordinates execution of instructions (1 mark)
  • Registers — tiny, fast storage locations inside the CPU (1 mark, alternative third component: Cache)
Describe the three stages of the fetch-decode-execute cycle. Name the registers used in the fetch stage. 5 marks

Mark scheme:

  • Fetch: The next instruction is retrieved from memory; the address is held in the PC, copied to the MAR, and the instruction is placed in the MDR (2 marks)
  • Decode: The Control Unit interprets the instruction to determine what operation is needed (1 mark)
  • Execute: The instruction is carried out, which may involve the ALU performing a calculation or data being transferred (1 mark)
  • Registers: Program Counter (PC), Memory Address Register (MAR), Memory Data Register (MDR) (1 mark)
Explain the difference between RAM and ROM. Give one example of data stored in each. 4 marks

Mark scheme:

  • RAM is volatile (data is lost when power is off); ROM is non-volatile (data is retained without power) (1 mark)
  • RAM can be read from and written to; ROM is read-only (1 mark)
  • RAM stores currently running programs and data, e.g. an open web browser or document (1 mark)
  • ROM stores permanent start-up instructions, e.g. the BIOS/UEFI (1 mark)
A small business needs to choose between an HDD and an SSD for their office computers. Discuss the advantages and disadvantages of each and make a recommendation. 6 marks

Mark scheme:

  • SSD advantage: Much faster read/write speeds so programs load quickly (1 mark)
  • SSD advantage: No moving parts so more durable and reliable (1 mark)
  • SSD disadvantage: More expensive per GB than HDD (1 mark)
  • HDD advantage: Lower cost per GB, available in very high capacities (1 mark)
  • HDD disadvantage: Slower, has moving parts that can fail, uses more power (1 mark)
  • Recommendation with justification, e.g. SSD for the operating system drive for fast boot times, with HDD or cloud storage for bulk file archiving (1 mark)
Explain the difference between a compiler and an interpreter. State one advantage of each. 4 marks

Mark scheme:

  • A compiler translates the entire source code into machine code at once, producing a standalone executable (1 mark)
  • An interpreter translates and executes the code one line at a time (1 mark)
  • Compiler advantage: The compiled program runs faster because no further translation is needed (1 mark)
  • Interpreter advantage: Errors are found immediately at the exact line, making debugging easier (1 mark)

Think About It

Understanding how computer hardware works is not just for people who build PCs. It genuinely helps you write better software:

Every line of Python you write eventually becomes machine code instructions that travel through the CPU’s fetch-decode-execute cycle. Understanding that journey — from your high-level print("Hello") to electrons flowing through transistors — is one of the most fascinating parts of computer science.

Video Resources

Interactive Activities

Interactive Games

Further Reading