Assume branch instructions occur 15% of the time and are predicted as not taken, while in practice they are taken 40% of the time with a penalty of 3 cycles. With forwarding, the load delay slot is one cycle and can be filled 60% of the time with useful instructions. 20% of the instructions are loads and 30% of these introduce load delay hazards. What is the New CPI due to load delay slots and branch hazards?
Query on pipelining co
answer is 0.213
load slots + branch delay slots
0.21 * 0.3 * 0.45 + 0.22 * 0.42 * 2 = 0.213
poonamk
#3
Hi, as we know we have to add time delay .so we have two time delay

branches. so for it
0 .15 0.4 3 = 0.18(for branch delay)

For loads
0.2 * 0.3* 0.4 = 0.024
so total CPI = 1 +0 .18 + 0.204(for loads)
total cpi. = 1.204 ans.
for more courses for GATE 2019