Beruflich Dokumente
Kultur Dokumente
Computer Organization
&
Assembly Language Programming
Outline
Introduction
Data Path Design
Register Transfer
Register Transfer Timing
Single Bus CPU Design
Two Bus CPU Design
Three Bus CPU Design
Hardwired Control
Microprogrammed Control
slide 2
Introduction
slide 3
Introduction
slide 4
Register Transfer
1. Y AX
2. Z Y + BX
3. AX Z
slide 5
slide 6
slide 7
slide 8
Synchronous vs.
Asynchronous Memory
Data transfer between the CPU and memory can
Transfer
slide 9
Synchronous vs.
Asynchronous Memory
In the asynchronus transfer, the CPU after requesting
Transfer
a memory operation waits until the memory indicates
CpuMemInterf.s wf
slide 10
Add1bus .s wf
slide 11
Jmp1bus .s wf
slide 12
slide 13
R1, 2
XCHG
R1, R2
slide 14
INC [R1]
CMP R1, R2
slide 15
Next
slide 16
Performance Considerations
slide 17
Control unit
Step A ction
1
MDRout , IR in
R1out , Y in , WMF C
slide 18
Micro
instruction
PCin
PCout
MARin
Read
MDRout
IRin
Yin
Select
Add
Zin
Z out
R1out
R1 in
R3out
WMFC
End
Figure7.15 AnexampleofmicroinstructionsforFigure7.6.
slide 19
Step
Action
1
MDRout , IRin
4
5
Offset-field-of-IR
out, Add, Zin
Zout, PCin , End
slide 20
CLK
Clock
IR
Controlstep
counter
Decoder/
encoder
External
inputs
Condition
codes
Controlsignals
Figure7.10.Controlunitorganization.
slide 21
Clock
CLK
Controlstep
counter
Reset
Stepdecoder
T 1 T2
Tn
INS1
External
inputs
INS2
IR
Instruction
decoder
Encoder
Condition
codes
INSm
Run
End
Controlsignals
Figure7.11. Separationofthedecodingandencodingfunctions.
Introduction to CPU Design
slide 22
Branch<0
Add
T7
Branch
T5
T4
T5
End
Figure7.13. GenerationoftheEndcontrolsignal.
Introduction to CPU Design
slide 23
Branch
T4
Add
T6
T1
Figure7.12.GenerationoftheZincontrolsignalfortheprocessorinFigure7.1.
slide 24
IR
Starting
address
generator
Clock
P C
Control
store
CW
Figure7.16. Basicorganizationofamicroprogrammedcontrolunit.
slide 25
External
inputs
IR
Clock
Startingand
branchaddress
generator
Condition
codes
PC
Control
store
CW
Figure7.18. Organizationofthecontrolunittoallow
conditionalbranchinginthemicroprogram.
slide 26
Address
Microinstruction
0
MDRout , IRin
3
Branchtostartingaddressofappropriate
microroutine
. ... .. ... ... .. ... .. ... ... .. ... ... .. ... .. ... ... .. ... .. ... ... .. ... ..
25
26
27
If N=0, then
branchtomicroinstruction0
Offset-field-of-IR
out ,SelectY, Add, Zin
Zout , PCin , End
slide 27
Micro in structio n
F1
F2
F3
F4
F5
F1 (4 bi ts )
F2 (3bit s)
F3 (3 bi t s)
F4 (4b it s)
F5(2b i ts)
00 00 :N otran sfer
00 01 :PC
out
00 10 :MD R
out
00 11 :Zo u t
01 00 :R0o u t
01 01 :R1o u t
01 10 :R2o u t
01 11 :R3o u t
10 10 :T E MP
out
10 11 :O ffset
out
00 0: No trans fer
00 1: MA Rin
01 0: MD Rin
01 1: T E MP
in
10 0: Yin
0 0 00: A dd
0 0 01: Su b
0 0: No acti on
0 1: Read
1 0: Wri te
F6
F7
F7 (1 bi t)
0 :SelectY
1 :Select4
0: No acti on
1: WMFC
16 A LU
fun cti ons
F8
F6(1b i t)
Figure7.19.
1 1 11: X OR
F8 (1bi t)
0: Co nt inu e
1: En d
An exampleofapartialformatforfieldencodedmicroinstructions.
slide 28
slide 29
Micro in struction
F0
F1
F2
F3
F0(8bits)
F1(3bits)
F2(3bi ts )
F3(3bits)
Addressofnex t
microins tru cti on
000:Notran sfer
001:PCo u t
010:MDRo ut
011:Zo u t
100:Rsrco u t
101:Rdsto u t
110:TEMPou t
000:Notransfer
001:MARin
010:MDRin
011:TEMP
in
100:Yin
F4
F5
F6
F7
F4(4bi ts )
F5 (2bits)
F6(1bit)
F7(1bit)
0000: Ad d
0001: Sub
00 :Noaction
01 :Read
10 :Write
0 :SelectY
1 :Select4
0 :No action
1 :W MFC
F9
F1 0
1111: XO R
F8
F8(1bi t)
F9(1bi t)
F1 0(1b it)
0:NextAdrs
1:InstDec
0:Noact io n
1:ORmo d e
0: Noaction
1: ORin d src
Figure7.23.
Formatformicroinstructionsin theexampleofSection7.5.3.
slide 30
IR
E xternal
Input s
Con diti on
codes
AR
Cont rolstore
IR
Next address
Microins tructiondecoder
Controlsignals
Figure7.22.Microinstructionsequencingorganization.
Introduction to CPU Design
slide 31