GATE Computer ScienceVery hardGATE CS (PYQ pattern)
A loop computes y[i] += A[i][j] × x[j] for a 64×64 matrix of 4-byte floats (A in row-major order at address 0, x at 16384, y at 17024); for each (i, j) it reads A[i][j] and x[j], and y[i] is read once per row. The data cache is 2 KB direct-mapped with 32-byte blocks. How many misses occur in total, and how many in a 2-way LRU cache of the same size, as (direct, 2-way)?
- A. (528, 528)
- B. (528, 1488)
- C. (1488, 1488)
- D. (1488, 528)
Correct answer: D. (1488, 528)
Simulate every reference. The compulsory minimum is 528; in the direct-mapped cache blocks of A and of x map to the same lines and keep evicting x, giving 1488, while 2-way LRU gives 528.
Practise more Computer Organization and Architecture questionsComputer Organization and Architecture: notes and key points
More Computer Organization and Architecture questions
- A 2²²-word memory uses a coincident (2-D) decoding scheme with a square cell array: one decoder selects the row, another the column. How…
- The IEEE 754 half-precision word 0xC4D0 (1 sign bit, 5 exponent bits with bias 15, 10 fraction bits) represents which value?
- A 16 KB, 4-way set-associative cache with 16-byte blocks uses 32-bit addresses. Its block size is doubled to 32 bytes and, at the same…
- A processor's logic takes 60 ns per instruction unpipelined. Split into k stages, the cycle time is 60/k + L ns (L = latch overhead) and…
- A DRAM controller uses an open-page policy: a row-buffer hit costs 15 ns and a miss 45 ns (precharge + activate + column). Under a…
- An in-order 2-issue processor starts up to two consecutive instructions per cycle. The second is issued with the first only if it has no…