GATE Computer ScienceVery hardGATE CS (PYQ pattern)

Ideal CPI is 1. Every instruction fetch misses the L1 I-cache 2% of the time; 30% of instructions are loads/stores and miss the L1 D-cache 5% of the time. Every L1 miss goes to L2 (10 cycles), which misses locally 20% of the time (memory adds 100 cycles). In addition, 30% of D-cache misses evict a dirty block whose write-back to L2 stalls the processor 10 more cycles. What is the CPI?

  1. A. 1.495
  2. B. 4.895
  3. C. 2.050
  4. D. 2.095

Correct answer: D. 2.095

L1 misses per instruction = 0.02 + 0.3 × 0.05 = 0.035, each costing 10 + 0.2 × 100 = 30 cycles → 1.05. Dirty write-backs: 0.015 × 0.3 × 10 = 0.045. CPI = 2.095. Forgetting the I-cache gives 1.495; charging memory to every L1 miss gives 4.895; dropping the write-backs gives 2.050.

More Computer Organization and Architecture questions

Exams that ask this topic