The read access times and the hit ratios for different caches in a memory…
2017
The read access times and the hit ratios for different caches in a memory hierarchy are as given below:

The read access time of main memory in 90nanoseconds. Assume that the caches use the referred-word-first read policy and the write-back policy. Assume that all the caches are direct mapped caches. Assume that the dirty bit is always 0 for all the blocks in the caches. In execution of a program, 60% of memory reads are for instruction fetch and 40% are for memory operand fetch. The average read access time in nanoseconds (up to 2 decimal places) is _________
Attempted by 61 students.
Show answer & explanation
Correct answer: 4.72
Key insight: treat each access path (instruction fetch via I-cache, data read via D-cache) separately and weight their average times by their usage frequency.
Compute the miss penalty from L1 to memory (same for both I-cache and D-cache): L2 access time + probability L2 misses × main memory time = 8 + (1 − 0.9) × 90 = 8 + 9 = 17 ns.
Average access time for instruction fetches (I-cache): 2 + (1 − 0.8) × 17 = 2 + 0.2 × 17 = 5.40 ns.
Average access time for data reads (D-cache): 2 + (1 − 0.9) × 17 = 2 + 0.1 × 17 = 3.70 ns.
Overall average read access time = 0.60 × 5.40 + 0.40 × 3.70 = 3.24 + 1.48 = 4.72 ns (rounded to 2 decimal places).
A video solution is available for this question — log in and enroll to watch it.