Fetch / Execute Cycle
Fetch / Execute Cycle
Fetch / Execute Cycle
Register Purpose
PC program counter Holds the address of the next instruction to be
carried out
MAR memory address register Holds the address in memory that is currently
being used
MDR memory data register Holds the data or instructions that is being stored
in the address accessed by the MAR
ADD the values found in memory locations 428 and 884 and
store the result in location 800
Instruction Fetch (IF)
Execution begins by moving the instruction at the
address given by the PC (PC 2200) from memory to the
control unit
42
12
Instruction Execution (EX)
For this ADD instruction, the addition circuit adds the two
source operands together to produce their sum
54
Return Result (RR)
RR returns the result of EX to the memory location
specified by the destination address.
54
Example of Program Execution
16
Instruction Format
List of Opcodes
Example of Program Execution
17
Jump instructions
18
What
A JUMP instruction tells the CPU to jump to a specific instruction out of sequence
1. The address part of the instruction from the IR is copied into the PC
2. This means the address in the PC is the address of the new instruction
Jump Instruction
When the jump Central Processing Unit
instruction is being
executed: Control Unit
MDR 00100110