Title: COMP 4300 Computer Architecture Datapath
1COMP 4300 Computer Architecture Datapath
Dr. Xiao Qin Auburn Universityhttp//www.eng.aubu
rn.edu/xqin xqin_at_auburn.edu
Fall, 2010
2Datapath for Branch Instructions
beq rs, rt, offset
if (Rrs Rrt) then PC ? PC4
s_extend(offsetltlt2)
3Datapath More Detailed View
4Simple Implementation
- Include the functional units we need for each
instruction
5RTL Code for MIPS add
- Fetch
- Instruction ROMPC, PCPC4
- Read Operands
- ALUOp1 Registersrs-value,
- ALUOp2 Registersrt-value
- Add
- ALUOut ALUOp1ALUOp2
- Write Result
- Registersrd-value ALUOut
6Datapath Components for MIPS add
add R1, R2, R3
7Datapath Connections for MIPS add
add R1, R2, R3
Interconnections
What is missing?
8Critical Path for MIPS add
add R1, R2, R3
CLK
Interconnections
Critical path
9Datapath Components for MIPS lw/sw
lw R1, -100(R2) sw R1, -100(R2)
16
ROM
Instruction Memory
REGISTERS
Data Memory
10Connections for lw
lw R1, -100(R2)
ALU
16
ROM
Instruction Memory
REGISTERS
Data Memory
11Critical Path for lw
lw R1, -100(R2)
12Connections for sw
sw R1, -100(R2)
Data
Port1
WriteRegister
ALU
ReadRegister1
16
Port2
ROM
ReadRegister2
Instruction Memory
REGISTERS
Address
DataOut
DataIn
RAM
Data Memory
13Critical Path for sw
sw R1, -100(R2)
Data
Port1
WriteRegister
ALU
ReadRegister1
16
Port2
ROM
ReadRegister2
Instruction Memory
REGISTERS
Address
DataOut
DataIn
RAM
Data Memory
14Datapath Connections for MIPS add and lw
add R1, R2, R3
CLK
15Datapath Connections for MIPS add and lw
16Combined Datapath R-Type and Load/Store
Instructions
17Combined Datapath Executing an R-Type
Instruction
add rd,rs,rt
18Combined Datapath Executing a load instruction
lw rt,offset(rs)
19Combined Datapath Executing a store instruction
sw rt,offset(rs)
20Summary