Skip to content
GATEiit

GATE CSE 2020 Q53: Speedup of a 5-stage pipeline with memory and branch stalls

Question

Consider a non-pipelined processor operating at 2.5 GHz. It takes 5 clock cycles to complete an instruction. You are going to make a 5-stage pipeline out of this processor. Overheads associated with pipelining force you to operate the pipelined processor at 2 GHz. In a given program, assume that 30% are memory instructions, 60% are ALU instructions and the rest are branch instructions. 5% of the memory instructions cause stalls of 50 clock cycles each due to cache misses and 50% of the branch instructions cause stalls of 2 cycles each. Assume that there are no stalls associated with the execution of ALU instructions. For this program, the speedup achieved by the pipelined processor over the non-pipelined processor (round off to 2 decimal places) is _______.

Try it: numerical answer: type the value

Numerical answer. No negative marking.
Show answer and explanation

Answer: 2.15 to 2.18 (official GATE 2020 final answer key)

Concept used: Speedup = (non-pipelined time per instruction) / (pipelined CPI × pipelined cycle time).

First step: Non-pipelined: 5×0.4=25 \times 0.4 = 2 ns. Pipelined CPI =1+0.3×0.05×50+0.1×0.5×2= 1 + 0.3 \times 0.05 \times 50 + 0.1 \times 0.5 \times 2, at 0.5 ns per cycle.

Full step-by-step solution

Detailed working, common mistakes and linked mock tests will be available with a free GATEiit account. Log-in is coming soon.

Share this question

WhatsAppDownload image

Source: official GATE 2020 CS question paper and final answer key, organised by IIT Delhi. Question paper · Answer key