EWRF - 12-112-1This SetMaterial from Section 4.3This set...

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

View Full Document Right Arrow Icon

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

View Full DocumentRight Arrow Icon

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

View Full DocumentRight Arrow Icon

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

View Full DocumentRight Arrow Icon

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

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

Unformatted text preview: 12-112-1This SetMaterial from Section 4.3This set under construction.OutlineBranch Prediction OverviewBimodal (One-Level) PredictorCorrelating (Two-Level) Predictors: local, global, gshareOther topics to be added.Sample Problems12-1EE 4720 Lecture Transparency. Formatted 9:27, 8 April 2011 from lsli12.12-112-212-2Branch and Target PredictionMotivationBranches occur frequently in code.At best, one cycle of branch delay; more with dependencies.Therefore, impact on CPI is large.TechniquesBranch Prediction:Predict outcome of branch. (Taken or not taken.)Branch Target Prediction:Predict branch or other CTIs target address.12-2EE 4720 Lecture Transparency. Formatted 9:27, 8 April 2011 from lsli12.12-212-312-3Branch PredictionMethods Coveredbimodal, a.k.a.One-level predictorCorrelating (Two-Level) PredictorsGlobal History, a.k.a.GAg.gshare.Local History, a.k.a.PAg.12-3EE 4720 Lecture Transparency. Formatted 9:27, 8 April 2011 from lsli12.12-312-412-4Branch Prediction IdeaIdea: Predict using past behavior.Example:LOOP:lwr1, 0(r2)# Load random number, either 0 or 1.addir2, r2, 4sltr6, r2, r7beqr1, r0 SKIP# T N N TN T T T N# Random, no pattern.nopaddir3, r3, 1SKIP:bneqr6, r0 LOOP# T T T. . .T N T T T# 99 Ts, 1 N, 99 Ts, ...nopSecond branch,bneq, taken 99 out of 100 executions.Pattern forbneq: T T T. . .T N T T TFirst branch shows no pattern.12-4EE 4720 Lecture Transparency. Formatted 9:27, 8 April 2011 from lsli12.12-412-512-5Prediction AccuracySPEC89 benchmarks on IBM POWER (predecessor to PowerPC).18%tomcatvspiceSPEC89benchmarksgccli2%4%6%8%10%12%14%16%0%1%5%9%9%12%5%10%18%nasa7matrix300doducfppppespressoeqntott1%0%Frequency of mispredictionsFIGURE 4.14 Prediction accuracy of a 4096-entry two-bit prediction buffer for the SPEC89 benchmarks.12-5EE 4720 Lecture Transparency. Formatted 9:27, 8 April 2011 from lsli12.12-512-612-6nasa71%0%matrix3000%0%tomcatv1%0%doducspiceSPEC89benchmarksfppppgccespresso eqntottli0%2%4%6%8%10% 12% 14%16%18%4096 entries:2 bits per entryUnlimited entries:2 bits per entryFrequency of mispredictions5%5%9%9%9%9%12%11%5%5%18%18%10%10%FIGURE 4.15 Prediction accuracy of a 4096-entry two-bit prediction buffer versus an infinite buffer for the SPEC89 benchmarks.12-6EE 4720 Lecture Transparency. Formatted 9:27, 8 April 2011 from lsli12.12-612-712-7Branch Prediction TerminologyOutcome:[of a branch instruction execution].The outcome of the execution of a branch instruction.Resolution:[of a branch].The determination of the branch outcome (by comparing register values or condition-code bits)and whether the prediction was correct.T:A taken branch.N:A branch that is not taken.Prediction:[made by branch prediction hardware].The predicted outcome of a branch....
View Full Document

This note was uploaded on 07/18/2011 for the course EE 4720 taught by Professor Staff during the Spring '08 term at LSU.

Page1 / 37

EWRF - 12-112-1This SetMaterial from Section 4.3This set...

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