William Stallings Computer Organization and Architecture 8 Edition
William Stallings Computer Organization and Architecture 8 Edition
William Stallings Computer Organization and Architecture 8 Edition
Computer Organization
and Architecture
8 Edition
th
Chapter 15 Control Unit
Operations
Damian Browne
15.1 Micro-Operations
The operation of a computer in executing a
program consists of a sequence of Instruction
Cycles, with one machine instruction per
cycle.
Each instruction cycle can be subdivided into
small units. One comprises fetch, indirect,
execute and interrupt, with only the fetch and
execute cycle always occurring.
These smaller cycles involves a series of steps
referred to as Micro-operations because each
step is simple and does very little.
Constituent Elements of
Program Execution
An instruction cycle' (also called fetch-and-
execute cycle, fetch-decode-execute cycle, and
FDX) is the time period during which a computer
processes a machine language instruction from its
memory or the sequence of actions that the central
processing unit (CPU) performs to execute each
machine code instruction in a program.
The name fetch-and-execute cycle is commonly used.
The instruction must be fetched from main memory,
and then executed by the CPU. This is fundamentally
how a computer operates, with its CPU reading and
executing a series of instructions written in its
machine language. From this arise all functions of a
computer familiar from the user's end.
Fetch - 4 Registers
Memory Address Register (MAR)
- Connected to address bus
- Specifies address for read or write operation
Memory Buffer Register (MBR)
- Connected to data bus
- Holds data to write or last data read
Program Counter (PC)
- Holds address of next instruction to be fetched
Instruction Register (IR)
- Holds last instruction fetched
Fetch Sequence
Address of next instruction is in PC
Address (MAR) is placed on address bus
Control unit issues READ command
Result (data from memory) appears on data
bus
Data from data bus copied into MBR
PC incremented by 1 (in parallel with data
fetch from memory)
Data (instruction) moved from MBR to IR
MBR is now free for further data fetches
Fetch Sequence (symbolic)
t1: MAR <- (PC)
t2: MBR <- (memory)
PC <- (PC) +1
t3: IR <- (MBR)
(tx = time unit/clock cycle)
or
t1: MAR <- (PC)
t2: MBR <- (memory)
t3: PC <- (PC) +1
IR <- (MBR)
Rules for Clock Cycle Grouping
Control signals
Signals to
within
control
processor
bus
Inputs
CLOCK
Outputs
Control Signal within processor
Internal Processor
Organization
Gates
HARDWIRED
IMPLEMENTATION
CONTROL UNIT OPERATION
HARDWIRED IMPLEMENTATION
INSTRUCTION REGISTER
CONTROL SIGNALS
. WITHIN CPU
FLAGS .
CONTROL BUS
.
CONTROL SIGNALS
CONTROL UNIT FROM CONTROL BUS
CLOCK
CONTROL SIGNALS
TO CONTROL BUS
CONTROL UNIT OPERATION
HARDWIRED IMPLEMENTATION
FLAGS
EACH INDIVIDUAL BIT
TYPICALLY HAS SOME
CONTROL BUS MEANING (E.G., OVERFLOW)
SIGNALS
SINGLE CONTROL C5
SIGNAL
PQ=00 FETCH CYCLE
PQ=01 INDIRECT CYCLE
NEW CONTROL SIGNALS, P & Q PQ=10 EXECUTE CYCLE
PQ=11 INTERRUPT CYCLE
c 5 P . Q .T2 P .Q.T2