Arithmetic Logic Unit (ALU)
Control Unit
Registers
Buses
Buses: Set of parallel wires which connect two or more components inside the CPU
- Width of bus = No. of parallel wires bus has. Width proportional to the no. of bits that can be transferred (8, 16, 32, 64 wires wide)
Data Bus: Bi-directional bus, bits carried in both directions.
- Used for transporting data & instructions between components
Address Bus: Transmits memory addresses specifying where data is sent to or retrieved from
- Width of the address bus proportional to the no. of
addressable memory locations.
Control Bus: Bi-directional,* transmits control signals between internal & external components*
- Coordinates use of the address & data buses &
provides status information between system components.
Control signals include:
- Bus request: shows a device is requesting use of the data bus
- Bus grant: shows that CPU has granted access to the data bus
- Memory write: data written into addressed location using this bus
- Memory read: data read from specific location to be placed onto the data bus
- Interrupt request: shows that a device is requesting access to CPU
- Clock: used to synchronise operations
Assembly Language
Pipelining
FDE Cycle & Registers
FDE Cycle: Sequence of operations that are completed in order to execute an instruction
Fetch:
- Address from the PC is copied to the MAR
- Instruction held at that address is copied to MDR by the data bus
- Simultaneously, the contents of the PC are incremented
- The value held in the MDR is copied to the CIR
Decode:
- The contents of CIR are split into operand and opcode
Execute :
- The decoded instruction is executed
Factors affecting CPU performance
Clock Speed: Determined by the system clock. The time taken for one clock cycle to complete
No. of Cores: Core is an independent processor that is able to run its own fetch-execute cycle
- Multiple cores can complete more than one fetch-execute cycle
- Not all programs are able to utilise multiple cores
efficiently
Amount & Type of Cache Memory: Cache memory is CPU’s onboard memory
- Instructions fetched from main memory are
copied to the cache, so if required again, they can be accessed quicker
- As cache fills up, unused instructions are replaced
Computer Architecture
Von Neumann Architecture:
- Basic components: Single control unit, ALU, registers, & memory units
- Utilizes shared memory and shared data bus for both data & instructions
- Built on the stored program concept
- Cheaper to develop, programs size can be optimised
Harvard Architecture:
- Physically separates memories for instructions & data
- Commonly used in embedded processors
- Useful when memories have different characteristics (e.g., read-only instructions, read-write data)
- Optimizes memory cell & bus sizes based on specific needs
- Allows larger word size for instructions by designing larger instruction memory
- Quicker execution, memories can be different sizes
Contemporary Processing