{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

Lecture_9 - Lecture 9 Pipelining(II 1 Data Hazards and...

Info icon This preview shows pages 1–8. Sign up to view the full content.

View Full Document Right Arrow Icon
Lecture 9: Pipelining (II) 1. Data Hazards and Forwarding 2. Control Hazard Solution 3. How to Handle Exception 1
Image of page 1

Info icon This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Datapath with Control C o n tro l M W B W B P C S rc ID /E X E X /M E M M E M /W B M u x 0 1 A d d B r a n c h A L U S r c 4 A d d A d d re s u lt S h ift le ft 2 RegWrite E X M W B IF /ID Write P C In s tru c tio n m e m o r y Instruction MemtoReg 0 0 R e g is te rs W rite re g is te r W rite d a ta R e a d d a ta 1 R e a d d a ta 2 R e a d re g is te r 1 R e a d re g is te r 2 M u x 1 A L U re s u lt Z e ro W rite d a ta R e a d d a ta M u x 1 A L U MemW A d d re s s D a ta m e m o ry A d d r e s s In s tru c tio n [2 0 – 1 6 ] A L U O p 1 6 3 2 In s tru c tio n [1 5 – 0 ] M u x 0 1 S ig n e x te n d A L U c o n tr o l M e m R e a d In s tru c tio n [1 5 – 1 1 ] 6 R e g D s t 1 H t i l t “d t f di ”? 1. How to implement “data forwarding”? 2. How to detect load-use hazard? How to stall pipeline? 3 How to resolve branch in the decode stage? 2 3. How to resolve branch in the decode stage? 4. How to flush pipeline?
Image of page 2