Processor Datapath & Control-1
Processor Datapath & Control-1
Architecture
op rs rt offset I-Format
6 bits 26 bits
op address J-Format
An Overview of the
Implementation
◼ For every instruction, the two steps are identical:
◼ Send the program counter (PC) to the memory that contains
Data
Register #
PC Address Instruction Registers ALU Address
Register #
Instruction
memory Data
Register # memory
Data
Overview: Processor
Implementation Styles
◼ Single Cycle
◼ perform each instruction in 1 clock cycle
◼ clock cycle must be long enough for slowest instruction; therefore,
◼ disadvantage: only as fast as slowest instruction
◼ Multi-Cycle
◼ break fetch/execute cycle into multiple steps
◼ perform 1 step in each clock cycle
◼ advantage: each instruction uses only as many cycles as it needs
◼ Pipelined
◼ execute each instruction in multiple steps
◼ perform 1 step / instruction in each clock cycle
◼ process multiple instructions in parallel – assembly line
Datapath: Instruction
Store/Fetch & PC Increment
Instruction
address
Add
PC
Instruction Add Sum
Instruction
4
memory
Read
PC address
a. Instruction memory b. Program counter c. Adder
Instruction
Instruction
Three elements used to store memory
PC
ADDR
Memory
RD Instruction
Datapath: R-Type Instruction
RegWrite
a. Registers b. ALU
5 5 5 Operation
3
RN1 RN2 WN
RD1
Register File ALU Zero
WD
RD2
RegWrite
Datapath:
Load/Store Instruction
3 ALU operation
Read
MemWrite register 1 MemWrite
Read
data 1
Read
Instruction register 2 Zero
Registers ALU ALU
Address Read Write Read
result Address
data 16 32 register data
Sign Read
Write data 2
extend Data
Write Data data
data memory memory
RegWrite Write
data
16 32
Sign MemRead
MemRead
extend