GATE Computer ScienceVery hardGATE CS
A loop body occupies the 160 bytes from address 0x1000 to 0x109F and runs 100 iterations. The instruction cache is direct mapped, 128 bytes with 16-byte blocks (8 lines), and starts empty; every instruction of the loop is fetched once per iteration in order. How many instruction-cache misses occur in total?
- A. 400
- B. 410
- C. 406
- D. 1000
Correct answer: C. 406
The loop has 10 blocks, but only 8 lines, so the 9th and 10th blocks evict those in lines 0 and 1. In steady state each iteration misses on 4 blocks (0, 1, 8 and 9), while blocks 2 to 7 hit, so the total is 10 + 99 × 4 = 406.
Practise more Computer Organization and Architecture questionsComputer Organization and Architecture: notes and key points
More Computer Organization and Architecture questions
- The 16-bit multiplier 0x6DB6 (0110 1101 1011 0110) is used by a Booth multiplier. Radix-2 Booth recoding performs one add or subtract for…
- Machines A and B run four benchmarks with execution times (in seconds) A: 12, 30, 8, 50 and B: 24, 15, 16, 25. Which statement is correct?
- A 32 KB direct-mapped cache has 64-byte blocks and the processor issues 32-bit byte addresses. How many tag bits does each cache line store?
- A program of 2×10⁹ instructions runs on a 1.5 GHz processor. The mix is 40% instructions of CPI 1, 30% of CPI 2, 20% of CPI 3 and 10% of…
- An unpipelined datapath needs 10 ns per instruction. A 5-stage pipelined version has a clock period of 2.5 ns (including latch overhead)…
- Sixty percent of a program's execution time can be sped up by a factor of 5 and the rest cannot. What is the overall speedup, to two…