




















Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!





















■
access to storage (general purpose registersand memory)
■
computational ability (ALU)
■
helper hardware (local registers and PC)
PC
instruction
memory
rt
rs
rd
registers
ALU
Data
memory
imm
Fetch
Register
Read
Back
Sequential laundry takes 8 hours for 4 loads
a
s k
r
d e
r
Time
Pipelined laundry takes 3.5 hours for 4 loads!
T a
s k
r
d e
r
Time
Pipelining doesn’t helplatency of single task, ithelps throughput of entireworkload
Multiple tasks operatingsimultaneously usingdifferent resources
Potential speedup =Number pipe stages
Time to “fill” pipeline andtime to “drain” it reducesspeedup:2.3X v. 4X in this example
Time
a s k
r
d e
r
Suppose newWasher takes 20minutes, new Stashertakes 20 minutes.How much faster ispipeline?
Pipeline rate limitedby slowest pipelinestage
Unbalanced lengthsof pipe stages alsoreduces speedup
Time
a s k
r
d e
r
Below is an illustration of the basic differencebetween executing four subtasks of a giveninstruction (in this case fetching
F
, decoding
D
,
execution
E
, and writing the results
W
) using
pipelining and sequential processing.
■
Consider the execution of
m
tasks (instructions)
using
n
-stages (units) pipeline.
■
n+m-1 time units
are required to complete
m
tasks.
Pipeline Hazard:
Matching socks in later load
A depends on D; stall since folder tied up
T a
s k
r
d e
r
bubble
Time
■
Instruction dependency refers to the casewhereby fetching of an instruction depends onthe results of executing a previous instruction.
■
Instruction dependency manifests itself in theexecution of a conditional branch instruction.
■
For example, in the case of a "branch if negative“instruction, the next instruction to fetch will not beknown until the result of executing that “branch ifnegative” instruction is known.