Tom Kelliher, CS 240
Apr. 17, 2002
Read 6.4 and 6.5.
Homework due 4/24, beginning of class: 6.3, 6.4, 6.7, 6.22.
Pipelined datapath.
Data hazards: forwarding and stalling.
Here's the datapath with control signals shown:

Questions:
This shows the control signals being generated during the instruction decode stage and being passed down the pipeline in parallel with the data:

The final, simple, pipelined processor:

This will demonstrate shortcomings of the simple pipelined processor. Can we find them all?
Consider the following MIPS code segment, assuming the following:
$7 = 4,
$8 = 2000,
$10 = 12, and
$11 = 20.
Top: lw $10, 0($8)
lw $11, 4($8)
slt $9, $11, $10
beq $9, $0, Label
sw $10, 4($8)
sw $11, 0($8)
Label: add $8, $8, $7