Professional Documents
Culture Documents
The Control Unit
The Control Unit
Tema 3: Transparencia: 2 / 73
La Unidad de Control
Contents
Elemental operations
Basic computer
– Main Memory
– Registers files
– Arithmetical-Logical Unit
– Addressing Unit
– Control Unit
Control signals timming
Instructions execution
Unit Control Design: wired vs. microprogrammed
Microprogramming and nanoprogramming: Motorola 68000
Computer exceptions
Booting up the computer
Bibliography
1
Tema 3: Transparencia: 3 / 73
La Unidad de Control
Tema 3: Transparencia: 4 / 73
La Unidad de Control
2
Tema 3: Transparencia: 5 / 73
La Unidad de Control
LA LB LC
Register A Register B Register C
TA TB TC
Data bus
Tema 3: Transparencia: 6 / 73
La Unidad de Control
LA LB
Register A Register B
ALU SelOp
Carry Register A to ALU
Carry Register B to ALU
Choose XOR operation LC
Register C
Load result in Register C
TC
Data Bus
3
Tema 3: Transparencia: 7 / 73
La Unidad de Control
REGISTER FILE
CPU
DEVICE
MAIN
MEMORY DEVICE
ALU I/O DEVICE
UNIT
DEVICE
CP DEVICE
CONTROL UNIT
Tema 3: Transparencia: 8 / 73
La Unidad de Control
4
Tema 3: Transparencia: 9 / 73
La Unidad de Control
señales
señales
MEM
MEM
LDIR
LDIR
RD
RD
WR
WR
vuelca
TMEM contenido lee el
al bus TMEM contenido
del bus
Ciclo de lectura tiempo
Ciclo de escritura tiempo
Reading cycle chronogram Writing cycle chronogram
Automatic Department Computers Structure and Organization.
Graduate in Computer Sciences / Graduate in Computer Engineering
Tema 3: Transparencia: 10 / 73
La Unidad de Control
5
Tema 3: Transparencia: 11 / 73
La Unidad de Control
Tema 3: Transparencia: 12 / 73
La Unidad de Control
Transfers accumulator
TAC Level Data transfer content to data bus
Transfiers accumulator
TALU content to addressses bus
Level Address transfer
6
Tema 3: Transparencia: 13 / 73
La Unidad de Control
Tema 3: Transparencia: 14 / 73
La Unidad de Control
7
Tema 3: Transparencia: 15 / 73
La Unidad de Control
Tema 3: Transparencia: 16 / 73
La Unidad de Control
8
Tema 3: Transparencia: 17 / 73
La Unidad de Control
Timming
Tema 3: Transparencia: 18 / 73
La Unidad de Control
9
Tema 3: Transparencia: 19 / 73
La Unidad de Control
Tema 3: Transparencia: 20 / 73
La Unidad de Control
10
Tema 3: Transparencia: 21 / 73
La Unidad de Control
DIR B registro A
TAC
TALU
LPC
LR
LFlags
RESET
periodo 1periodo 2periodo 3periodo 4.periodo 5periodo 6periodo 7periodo 8
Tema 3: Transparencia: 22 / 73
La Unidad de Control
Improving remarks:
– Fetch phase only gets one byte from memory in one byte data bus
length. So, two read operations must be done.
– 4th period is lost on decoding instruction machine code.
– Pc is updated on 5th and 6th periods. These periods can be avoid
if an adder exists only for the Addressing Unit.
– PC update takes one period if ALU results directly goes to
addresses bus or to data bus instead of storing them on
Accumulator Register
– We can overlap current instruction end phase with fetch of
following instruction
– Mind conflicts on buses
11
Tema 3: Transparencia: 23 / 73
La Unidad de Control
Instruction format:
Tema 3: Transparencia: 24 / 73
La Unidad de Control
CONTROL
ACTION ELEMENTAL OPERATION SIGNAL
Fetch
Address CP addresses bus TCP
Load addresses registere LDIR
Decoding 1 periodo de
retardo
12
Tema 3: Transparencia: 25 / 73
La Unidad de Control
CONTROL
ACTION ELEMENTAL OPERATION SIGNAL
Update PC
Add CP + 4 UC puts 4 on data bus DIT
Operands and operation selection <X0, X1 = B. Dat>
<Y0, Y1 = CP>
<Selop = sumar>
Load accumulator LAC
Tema 3: Transparencia: 26 / 73
La Unidad de Control
CONTROL
ACTION ELEMENTAL OPERATION SIGNAL
Calculate source
operan address
B selection + offset UC puts 1234h. Data bis DIT
UC generates B address <DIR A = B>
13
Tema 3: Transparencia: 27 / 73
La Unidad de Control
CONTROL
ACTION ELEMENTAL OPERATION SIGNAL
Store result
Put source operand on Transfer accumulator to addresses
data bus bus TALU
Load addresses register LDIR
Start memory cycle MEM
Read RD
Buffer memory Data bus TMEM
UC generates A address <DIR A = A>
Load register of the registers file LR
Tema 3: Transparencia: 28 / 73
La Unidad de Control
reloj
TCP
LDIR
MEM
RD
WR
TMEM
LI
DIT
bus de bus de
X0, X1 datos datos
Y0, Y1 CP puerto A
LAC
DIR A registro B registro A
DIR B
TAC
TALU
LPC
LR
RESET
14
Tema 3: Transparencia: 29 / 73
La Unidad de Control
reloj reloj
TCP TCP
LDIR LDIR
MEM MEM
TMEM TMEM
RD RD
WR WR
LI LI
DIT DIT
bus de bus de bus de
X0, X1 datos X0, X1 datos datos
Y0, Y1 CP Y0, Y1 CP CP
SELOP suma suma suma
SELOP
LAC LAC
DIR A DIR A
DIR B DIR B
TAC TAC
TALU TALU
LPC LPC
LR LR
LFlags LFlags
RESET RESET
periodo 1 periodo 2 periodo 3 periodo 4 periodo 5 periodo 6 periodo 7 periodo 1 periodo 2 periodo 3 periodo 4 periodo 5 periodo 6 periodo 7
15
Tema 3: Transparencia: 31 / 73
La Unidad de Control
Contents
Elemental operations
Basic computer
– Main Memory
– Registers files
– Arithmetical-Logical Unit
– Addressing Unit
– Control Unit
Control signals timming
Instructions execution
Unit Control Design: wired vs. microprogrammed
Microprogramming and nanoprogramming: Motorola 68000
Computer exceptions
Booting up the computer
Bibliography
Tema 3: Transparencia: 32 / 73
La Unidad de Control
Contents
Elemental operations
Basic computer
– Main Memory
– Registers files
– Arithmetical-Logical Unit
– Addressing Unit
– Control Unit
Control signals timming
Instructions execution
Unit Control Design: wired vs. microprogrammed
Microprogramming and nanoprogramming: Motorola 68000
Computer exceptions
Booting up the computer
Bibliography
16
Tema 3: Transparencia: 33 / 73
La Unidad de Control
INSTRUCTION
PHASES CONTROL
CONTROL
COUNTER
SIGNALS
UNIT
FLAGS
I/O
Tema 3: Transparencia: 34 / 73
La Unidad de Control
Advantages: Advantages:
– Faster circuits than stored ones – Instruction set can be modified
– Difficult to design
several instruction set. But only
one at once
– Difficult to modify
Drawback:
– Slow decoding
17
Tema 3: Transparencia: 35 / 73
La Unidad de Control
Tema 3: Transparencia: 36 / 73
La Unidad de Control
18
Tema 3: Transparencia: 37 / 73
La Unidad de Control
Tema 3: Transparencia: 38 / 73
La Unidad de Control
19
Tema 3: Transparencia: 39 / 73
La Unidad de Control
Tema 3: Transparencia: 40 / 73
La Unidad de Control
20
Tema 3: Transparencia: 41 / 73
La Unidad de Control
Tema 3: Transparencia: 42 / 73
La Unidad de Control
Control Unit Design (X)
Wired logic (VIII). States machine (VII)
Transition states equations (cont):
21
Tema 3: Transparencia: 43 / 73
La Unidad de Control
Tema 3: Transparencia: 44 / 73
La Unidad de Control
22
Tema 3: Transparencia: 45 / 73
La Unidad de Control
Tema 3: Transparencia: 46 / 73
La Unidad de Control
23
Tema 3: Transparencia: 47 / 73
La Unidad de Control
Signals equations:
Tema 3: Transparencia: 48 / 73
La Unidad de Control
Signals equations:
24
Tema 3: Transparencia: 49 / 73
La Unidad de Control
Tema 3: Transparencia: 50 / 73
La Unidad de Control
25
Tema 3: Transparencia: 51 / 73
La Unidad de Control
Tema 3: Transparencia: 52 / 73
La Unidad de Control
26
Tema 3: Transparencia: 53 / 73
La Unidad de Control
Tema 3: Transparencia: 54 / 73
La Unidad de Control
27
Tema 3: Transparencia: 55 / 73
La Unidad de Control
Tema 3: Transparencia: 56 / 73
La Unidad de Control
28
Tema 3: Transparencia: 57 / 73
La Unidad de Control
Tema 3: Transparencia: 58 / 73
La Unidad de Control
µinstructions decoding
– Horizontal µprogramming, when codification is not used
– Vertical µprogramming, µIs. Are codified
29
Tema 3: Transparencia: 59 / 73
La Unidad de Control
µinstrucciones coding
Control signals are grouped in:
– Data bus access – Addressing Unit control
– Addresses bus access signals
– ALU control signals – Flags
– Registers file control signals – I / O control signals
– Memory control signals
Tema 3: Transparencia: 60 / 73
La Unidad de Control
30
Tema 3: Transparencia: 61 / 73
La Unidad de Control
Tema 3: Transparencia: 62 / 73
La Unidad de Control
Control Signals
Sequence bit
Comparer
DEMU
Flags X
31
Tema 3: Transparencia: 63 / 73
La Unidad de Control
Tema 3: Transparencia: 64 / 73
La Unidad de Control
M68000 nanoprogramming
Two-level nanoprogramming
system:
– First level words are pointers to
second level ones
– Second level words are
differents
– Second level words activate /
desactivate a hardware piece
(horizontal microprogrammig)
Second level control word is 70 bits
length
32
Tema 3: Transparencia: 65 / 73
La Unidad de Control
Tema 3: Transparencia: 66 / 73
La Unidad de Control
33
Tema 3: Transparencia: 67 / 73
La Unidad de Control
Tema 3: Transparencia: 68 / 73
La Unidad de Control
34
Tema 3: Transparencia: 69 / 73
La Unidad de Control
Tema 3: Transparencia: 70 / 73
La Unidad de Control
35
Tema 3: Transparencia: 71 / 73
La Unidad de Control
Remaining bits:
Condition bit
Micro jump bit
End micro program bit / sequence of
instruction bit
Tema 3: Transparencia: 72 / 73
La Unidad de Control
Remaining bits:
Lets a control memory of 1K. It will
be necessary 10 bits to address it.
36
Tema 3: Transparencia: 73 / 73
La Unidad de Control
Tema 3: Transparencia: 74 / 73
La Unidad de Control
Exceptions
37
Tema 3: Transparencia: 75 / 73
La Unidad de Control
Tema 3: Transparencia: 76 / 73
La Unidad de Control
Bibliography
Estructura y diseño de computadores
David A. Patterson y John L. Hennessy. Reverté, 2000
Capítulo 5 y Apéndice C
Arquitectura de computadores
José A. de Frutos y Rafael Rico. Servicio de Publicaciones de la
Universidad de Alcalá, 1995
Capítulo 4.
Automatic Department Computers Structure and Organization.
Graduate in Computer Sciences / Graduate in Computer Engineering
38