retagged by
1,246 views
1 votes
1 votes
Consider a machine with 5-stage pipeline with 1ns clock cycle. The second machine with 12-stage pipeline with a 0.6ns clock cycle. The 5-stage pipeline experiences a stall due to data hazard for every 5 instructions, whereas 12 stage pipeline experiences 3 stalls for every 8 instructions. Branch instructions constitute 20% of the total instructions , and misprediction rate for both machines is 5%.
1.What is the speed up of 12-stage pipeline over 5 stage pipeline considering only data hazards?

2.If the branch mispredict penalty for the first machine is 2 cycles but the second machine is 5 cycles, what is the speed up of 12-stage pipeline over 5 stage pipeline?
retagged by

1 Answer

2 votes
2 votes
1.  Texe(Execution time) =N(No of instrucions)*CPI(clock per instruction) *Tclockp (clock period)

without any stall it need 1 clock cycle per instruction but here,

CPI=6/5 for machine-1

CPI=11/8 for machine-2

Speed UP= N * (6/5) * 1ns  / N * (11/8) * 0.6ns  =1.45

2. When prediction technique has been used some time it gives correct branch but not always so here that more penalty is given in terms of 2 and 5 cycles for machine1 and machine2 accordingly.So that CPI will going to be increase.Misprediction rate for both the machines are 5%.

        previously machine-1  = 6/5

                         Now 0.80 * 6/5 + 0.20 (6/5 + 0.05 *2)

                               =1.22

previously machine-2  = 11/8

                         Now 0.80 * 11/8 + .20 (11/8 +  0.05 *5)

                               =1.425

same way speed-up will be = N * 1.22 * 1 / N * 1.425 *0.6  =1.426

Related questions

0 votes
0 votes
2 answers
1
farmanahmed888 asked Jan 6, 2022
523 views
Which approach is correct?ASSIGNMENT LINK : https://nptel.ac.in/content/storage2/courses/106105163/ASSIGNMENT-SOLUTION-WEEK11.pdfnptel assignment q-1 Caption
1 votes
1 votes
0 answers
2
Nandkishor3939 asked Jan 19, 2019
771 views
In a processor each instruction execution completes in 4 clock cycle with 2.5 gigahertz. The same processor is transformed into a pipelined processor with five stages ope...
2 votes
2 votes
4 answers
3
3 votes
3 votes
0 answers
4
thepeeyoosh asked Jan 13, 2018
701 views
Actually, In this problem what will, we consider getting the answer(upper bound or lower bound) and why?