EEasy IGCSELabTracker

On a phone the notes, quizzes and tracker work fine. The 3D models and the practice lab are made for a laptop.

Specification points 3.1.1–3.1.5 ·

the CPU and microprocessor, Von Neumann components, the fetch–decode–execute cycle, cores, cache and clock, instruction sets and embedded systems.

1The CPU and the microprocessor

Definition

Central processing unit (CPU) — the part of the computer that processes the instructions and data that are input into the computer, so that the result can be output.

Microprocessor — a type of integrated circuit on a single chip. A CPU is normally built as a microprocessor.

2Components of a Von Neumann CPU

In a Von Neumann computer, the program's instructions and its data are stored together in the same memory (RAM) and are fetched into the CPU along the same buses.

CPU PC program counter MAR memory address register CIR current instruction register MDR memory data register ACC accumulator CU control unit clock (timing signals) ALU arithmetic logic unit address copied instruction copied RAM instructions and data address contents 0100instruction 0101instruction 0110data 0111data …… Address bus one way Data bus two way Control bus — two way (control and timing signals)
Figure 1. The units and registers inside the CPU, and the three buses that connect it to RAM.

Name the parts of the CPU

Loading the interactive…

A register is a very small, very fast storage location inside the CPU that holds one item: an address, an instruction or a piece of data.

Component Purpose
Control unit (CU) Controls the FDE cycle: decodes each instruction and sends control signals to the other components
Arithmetic logic unit (ALU) Carries out arithmetic (e.g. add, subtract) and logic operations (e.g. AND, OR, comparisons)
Program counter (PC) Holds the address of the next instruction to be fetched
Memory address register (MAR) Holds the address of the memory location about to be read from or written to
Memory data register (MDR) Holds the data or instruction just read from memory, or about to be written to memory
Current instruction register (CIR) Holds the instruction currently being decoded and executed
Accumulator (ACC) Holds the result of calculations carried out by the ALU, temporarily
Address bus Carries addresses from the CPU (MAR) to memory — one way only
Data bus Carries data and instructions between the CPU (MDR) and memory — two way
Control bus Carries control signals (e.g. read, write) and timing signals from the CU — two way

3The fetch–decode–execute (FDE) cycle

The CPU runs a program by repeating the FDE cycle for every instruction: fetch the instruction from RAM into the CPU, decode it, then execute it.

FETCHDECODEEXECUTE 1The address of the next instruction, held in the PC, is copied to the MAR.PC → MAR2The address is sent to RAM on the address bus; the CU sendsa read signal on the control bus.address bus, control bus3The instruction stored at that address is sent on the data bus to the MDR.RAM → data bus → MDR4The instruction is copied from the MDR to the CIR.MDR → CIR5The PC is incremented by 1, so it now holds the address of the next instruction.PC + 16The CU decodes the instruction in the CIR: it works out which operationto carry out and what data is needed.CU7The CU sends control signals on the control bus to the components thatcarry out the instruction; any data needed is fetched via the MAR and MDR.CU, control bus8Arithmetic and logic operations are done by the ALU; results are held in the ACC.ALU → ACC repeat for the next instruction
Figure 2. The FDE cycle. The right-hand column names the registers, buses and units used at each step.

Step through fetch–decode–execute

Loading the interactive…

4Cores, cache and clock — CPU performance

Feature What it is How it affects performance
Core One complete processing unit (its own CU, ALU and registers) in the CPU More cores → more instructions processed at the same time. Not always faster in proportion: the task must be divisible between cores, and the cores must communicate with each other
Cache Small, very fast memory in or next to the CPU that holds frequently used instructions and data The CPU checks cache before RAM. A larger cache → more items found in cache → fewer slower fetches from RAM.
Clock Produces timing signals; clock speed = number of cycles per second (e.g. 3.5 GHz) Faster clock → more FDE cycles per second → more instructions processed per second. Too high a speed causes overheating and instability

5Instruction set

Definition

Instruction set — the list of all the commands that a CPU can process. The commands are machine code (binary).

Every program must be in the CPU's own machine code before it can run, so the instruction set fixes the only operations the CPU can carry out, and different types of CPU can have different instruction sets.

6Embedded systems

Definition

Embedded system — a small computer system, built into a larger device, that performs a dedicated function (one task, or a small set of tasks).

Embedded system
  • Dedicated function; the user cannot install new software to change the task
  • Controlled by a microprocessor (often a single chip); program usually stored in ROM
  • Small, low power, cheap to make in large numbers
  • Often reacts to sensor input in real time
  • Devices: domestic appliances (washing machine, microwave oven), cars (engine management, anti-lock brakes, sat nav), security systems, lighting systems, vending machines
General purpose computer
  • Performs many different functions
  • Runs an operating system and whatever software the user installs
  • Larger, uses more power, costs more
  • Devices: personal computer (PC), laptop
Traps
Wrong Right
The PC holds the current instruction. The PC holds the address of the next instruction; the CIR holds the current instruction.
The address bus is two way. Only the data and control buses are two way; addresses go one way, from CPU to memory.
Doubling the cores doubles the speed. Cores must share and coordinate work, so the gain is less than double.

Quick check

12 multiple-choice questions. Pick an answer to see whether it is right and why.

  1. What is a microprocessor?

  2. Which register holds the instruction currently being decoded and executed?

  3. At the start of a fetch the PC holds the address 200. What does the PC hold when that fetch is complete?

  4. In the fetch stage, what happens directly after the instruction arrives in the MDR?

  5. Which statement about the buses is correct?

  6. An instruction adds two numbers. Which component does the addition, and where is the result held?

  7. In a Von Neumann computer, where are a program's instructions and its data stored?

  8. Why can a larger cache improve the performance of a CPU?

  9. What is the effect of a faster clock speed?

  10. Why does doubling the number of cores not always double the speed of a CPU?

  11. What is an instruction set?

  12. Which of these is a feature of an embedded system?

Exam-style questions

Write your answer, then show the answer and compare. Nothing here is marked for you: you decide how close you were. What you write is saved in this browser.

Recall

1

State the role of the CPU.

1 mark
2

What is a microprocessor?

1 mark
3

Name the register that holds the address of the next instruction.

1 mark
4

Name the bus that carries addresses and state its direction.

2 marks
5

What is an instruction set?

2 marks

Understanding

6

Describe the purpose of the MAR and the MDR.

2 marks
7

Explain why a larger cache can improve the performance of a CPU.

2 marks
8

Explain why doubling the number of cores may not double the performance of a CPU.

2 marks

Application

9

A washing machine is controlled by an embedded system. Describe two characteristics of an embedded system, using the washing machine as the example.

4 marks
10

Identify which of these contain an embedded system: laptop, vending machine, car anti-lock brakes, desktop PC, security alarm.

3 marks

Exam-style

11

Describe the stages of the fetch–decode–execute cycle, including the role of the registers and buses.

6 marks
12

A computer's clock speed is increased from 2.4 GHz to 3.6 GHz. Explain how this affects its performance.

3 marks

How well do you know this?

Rate each specification point. It is saved to your tracker as a new revision round.

All points:
  • 3.1.1
    • Understand the role of the central processing unit (CPU) in a computer
    • Understand what is meant by a microprocessor
  • 3.1.2
    • Understand the purpose of the components in a CPU, in a computer that has a Von Neumann architecture
    • Describe the process of the fetch–decode–execute (FDE) cycle, including the role of each component in the process
  • 3.1.3Understand what is meant by a core, cache and clock in a CPU and explain how they can affect the performance of a CPU
  • 3.1.4Understand the purpose and use of an instruction set for a CPU
  • 3.1.5Describe the purpose and characteristics of an embedded system and identify devices in which they are commonly used

Settings

Your subjects

Untick the subjects you don't take. They leave the menu, the home page and the tracker. Your ratings are kept, so you can bring a subject back at any time.

Page style

Colours