Professional Documents
Culture Documents
L14 Pipelining 3
L14 Pipelining 3
Lecture – 14
The task of the instruction fetch unit is to
supply the next stage of pipelining with a
steady stream of instructions.
Whenever, this stream is interrupted, pipeline
get stalled and this situation is called
Instruction Hazards.
Cache miss and Branch instruction is two
important cases where instruction hazard can
occur.
09/23/22 Sumaiya Iqbal, Lecturer, CSE, BUET
The effect of cache miss on pipelining and
then the delay occurred for fetching the
instruction from main memory has already
shown.
Here, we will examine how branch instruction
affects the performance of pipelining.
We will first examine the unconditional
branch instructions.
Instruction
I1 F1 E1
I3 F3 X
Ik Fk Ek
I F 1 D 1 E 1 W 1
1
I 2 (Branch) F 2 D 2 E 2
I F 3 D 3 X
3
I 4 F 4 X
I k F k D k E k W k
I k+ 1 F k+ 1 D k+ 1 E k+ 1
T ime
Clock c ycle 1 2 3 4 5 6 7
I F 1 D 1 E 1 W 1
1
I 2 (Branch) F 2 D 2
I F 3 X
3
I k
F k D k E k W k
I k+ 1 F k+ 1 D k+ 1 E k+ 1
I1 F1 D1 E1 E1 E1 W1
I2 F2 D2 E2 W2
I3 F3 D3 E3 W3
I4 F4 D4 E4 W4
I 5 (Branch) F5 D5
I6 F6 X
Ik Fk Dk Ek Wk