Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

re https//uahinstructure.com/courses/26845/quizzes/42069/take 2.14: 1.86: 1.9 D

ID: 3733100 • Letter: R

Question

re https//uahinstructure.com/courses/26845/quizzes/42069/take 2.14: 1.86: 1.9 D | Question 14 7 pts A processor has a branch-target buffer. If a branch is in the buffer and it is correctly predicted, there is no branch penalty. The prediction rate is 90% correct. If it is incorrectly predicted, the penalty is 3 cycles. If the branch is not in the buffer, and not taken, the penalty is 2 cycles, 70% of branches are taken. If the branch is not in the buffer and is taken, the penalty is 4 cycles. The probability that a branch is in the buffer if 95%, what is the average branch penalty? 1275 1.005 0.825 0.455 D Question 15 5 pts The following sequence of branch outcomes is applied to a saturating counter branch predictor TNTTTNNNTTTNNNTTTNNT How many incorrect predictions are made? The predictor should start in the Strongly Taken state.

Explanation / Answer

Answer -
Case 1 - When branch is in buffer-
Probability of branch is in buffer = 95% = .95
Probabilty it is correctly predicted = 90% = .9
Probability it is incorrectly predicted = 100 - 90 = 10% i.e .1
Panelity for correct prediction = 0
Panelity for incorrect prediction = 3 cycles
So
let,average banch panelity when branch in buffer = t1

t1= .95 * ( 0.1 * 3 ) = 0.285

Case2-When branch is not in buffer-
Probability of branch is not in buffer = (100- 95)% = 5 i.e .05
Probability of branch is not in buffer and taken = 70% = .7
Probability of branch is not in buffer and not taken= 100 - 70 = 30% i.e .3
Penality for branch is not in buffer and taken = 4 cycles
Penality for branch is not in buffer and not taken= 2 cycles
So
let,average banch penality when branch is not in buffer = t2
t2= .05 * ( (0.3 * 2) +(0.7*4)) = 0.17
total average penalty = t1+t2 = 0.285 +0.17 = 0.455 [ ANSWER ]