Appearance
B1 · Computer Architecture
Spec reference: Section B1 - Computer Architecture Key idea: Understand Von Neumann and Harvard architecture, cluster computing, emulation, and the factors affecting architecture choice.
The stored program model
The stored program model means that both a program's instructions and its data are stored together in the same memory. The CPU fetches and executes instructions one at a time from memory.
Von Neumann Architecture
The most common architecture for general-purpose computers.
Key features:
- A single shared memory stores both instructions and data.
- A single bus (pathway) connects the CPU to memory.
- Instructions are fetched, decoded and executed sequentially.
- The CPU contains the ALU, CU, and registers.
Limitation: The Von Neumann bottleneck. Because instructions and data share one bus, only one can be transferred at a time, which limits speed.
Harvard Architecture
Key features:
- Separate memory and separate buses for instructions and data.
- Instructions and data can be fetched simultaneously.
- Faster than Von Neumann for certain tasks.
Used in: Microcontrollers, DSPs (digital signal processors), and some embedded systems.
| Feature | Von Neumann | Harvard |
|---|---|---|
| Memory | Shared for data and instructions | Separate for data and instructions |
| Buses | Single shared bus | Separate buses |
| Speed | Limited by bottleneck | Faster (simultaneous fetch) |
| Complexity | Simpler design | More complex |
| Use | General-purpose PCs, laptops | Embedded systems, microcontrollers |
Cluster computing
A cluster is a group of computers connected together and working as a single system. Each computer in the cluster (called a node) works on part of a larger task.
Benefits:
- Higher processing power than a single machine.
- If one node fails, others continue (high availability).
- Can scale by adding more nodes.
Used in: Scientific simulations, search engines, weather forecasting, rendering farms.
Uniform Memory Access (UMA) vs Non-Uniform Memory Access (NUMA)
| Type | Description |
|---|---|
| UMA | All processors share the same memory and have equal access time. Simple but does not scale well to many processors. |
| NUMA | Each processor has its own local memory. Accessing local memory is fast; accessing another processor's memory is slower. Scales better for multi-processor systems. |
Emulation
Emulation is using software to replicate the behaviour of one system on a different system.
Examples:
- Running old console games on a modern PC using an emulator.
- Testing mobile apps on a desktop before deploying to a phone.
- Running a different OS inside a virtual machine.
Implications:
- Allows legacy software to run on modern hardware.
- Slower than running natively because the emulator must translate every instruction.
- Used in software testing, virtualisation, and preservation.
Factors affecting choice of architecture
| Factor | Consideration |
|---|---|
| Performance requirements | Does the application need high speed or real-time processing? |
| Cost | Cluster computing is expensive; embedded systems need cheap microcontrollers |
| Power consumption | Mobile and embedded devices need low-power Harvard architectures |
| Scalability | Cluster and NUMA systems scale better than single-processor Von Neumann |
| Complexity | Von Neumann is simpler to program; Harvard requires separate memory management |
| Use case | General-purpose tasks vs specific real-time processing |
Summary
| Term | Meaning |
|---|---|
| Von Neumann | Architecture with shared memory and single bus for data and instructions |
| Harvard | Architecture with separate memory for data and instructions |
| Von Neumann bottleneck | Limitation caused by sharing one bus for both data and instructions |
| Cluster computing | Multiple computers working together as one system |
| NUMA | Each processor has its own local memory for faster access |
| Emulation | Software that mimics the behaviour of another system |