In a direct-mapped cache with 16 lines, to which line does main memory block number 75 map?
Correct answer A. 11
Explanation
Direct mapping places block j in line j mod (number of lines), so 75 mod 16 = 11 (75 = 4 x 16 + 11). The answer 4 is the quotient, which becomes the tag stored with the line. Any other block whose number leaves remainder 11, such as 11, 27 or 43, competes for the same line, which is the source of conflict misses.
Answer checked How we write and check questions
Discussion