lec10 - ± Example: special instructions to check for FP...

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

View Full Document Right Arrow Icon
LECTURE - 10
Background image of page 1

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

View Full DocumentRight Arrow Icon
Data Hazards CC1 CC2 CC3 CC4 CC5 CC6 CC7 CC8 CC9 CC10 CC11 MULTD F0, F4, F6 IF ID M1 M2 M3 M4 M5 M6 M7 MEM WB ... IF ID EX MEM WB ... IF ID EX MEM WB ADDD F2, F4, F6 IF ID A1 A2 A3 A4 MEM WB ... IF ID EX MEM WB LD F2, 0(R2) IF ID EX MEM WB WAW hazard: an example CC1 CC2 CC3 CC4 CC5 CC6 CC7 CC8 CC9 CC10 CC11 CC12 LD F4, 0(R2) IF ID EX MEM WB MULTD F0, F4, F6 IF ID STL M1 M2 M3 M4 M5 M6 M7 MEM
Background image of page 2
Handling WAW Hazards ± Occurs only when the result of ADDD is overwritten without any instruction using it! ² Otherwise, RAW hazard stall would have occurred ± Hazard can be detected in ID stage of latter instruction ± Two ways to handle: ² Delay issue of load until ADDD enters MEM ² Stamp out result of ADDD
Background image of page 3

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

View Full DocumentRight Arrow Icon
Control Hazard Complications ± An example: ² DIVF F0, F2, F4 // Finishes last; excepn. ² ADDF F10, F10, F8 // Finishes first ² SUBF F12, F12, F14 // Finishes second ± Out-of-order completion causes problems! ² Precise exceptions are difficult to implement
Background image of page 4
Achieving Precise Exceptions ± Approach 1: Ostrich algorithm ² Don't care ² May be provide a slower precise mode
Background image of page 5

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

View Full DocumentRight Arrow Icon
Background image of page 6
Background image of page 7

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

View Full DocumentRight Arrow Icon
Background image of page 8
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: ± Example: special instructions to check for FP exceptions ± Approach 2: allow instruction issue to continue only if previous instructions will complete without exception ² Stall to maintain precise exceptions Achieving Precise Exceptions (continued) ± Approach 3: save state to undo ² Two possibilities ± History file: keep track of original value of registers ± Future file: keep track of current value; main register file updated after all previous instructions are done ² More buffer space required ² Hazard checks and control become very complex Achieving Precise Exceptions (continued) ± Approach 4: imprecise, but keep enough state for OS to recover ² Keep track of incomplete instructions ² OS then runs those instructions before returning control ² Complicated to execute these instructions properly! Further Topics. .. ± Instruction Level Parallelism (ILP)...
View Full Document

This note was uploaded on 07/14/2011 for the course CS 422 taught by Professor Hogakoi during the Spring '10 term at IIT Kanpur.

Page1 / 8

lec10 - ± Example: special instructions to check for FP...

This preview shows document pages 1 - 8. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online