# MadeEasy Subject Test: CO & Architecture - Cache Memory

2 votes
256 views

Suppose that in 250 memory references there are 30 misses in first level cache and 10 misses in second level cache. Assume that miss penalty from the L2 cache memory are 50 cycles. The hit time of L2 cache is 10 cycles. The hit time of the L1 cache is 5 cycles. If there are 1.25 memory references per instruction, then the average stall cycles per instruction is ________.

edited
0

## 1 Answer

1 vote
• Miss penalty of L1 = hit time of L2 + (miss rate of L2 * miss penalty of L2), (Therefore, we can see that miss penalty of L1 already includes miss penalty of L2)
• Therefore, miss penalty of L1 = 10 c + ((10/30) * 50) c = (80/3) c
• No. of stalls per memory reference = miss rate of L1 * miss penalty of L1 ,(Stalls are introduced due to misses in L1 cache)
• Therefore, No. of stalls per memory reference = (30/250) * (80/3) = (16/5) stalls
• Since each instruction makes 1.25 mem references (given), therefore, No. of stalls per instruction = (16/5) * 1.25 = 4 stalls

edited
0

Hope u get

## Related questions

0 votes
1 answer
1
158 views
0 votes
2 answers
2
218 views
Suppose that in $250$ memory references, there are $30$ misses in first level cache and $10$ misses in second level cache. Assume that miss penalty from the L2 cache memory $50$ cycles. The hit time of L2 cache is $10$ cycles. The hit time of the L1 ... $1.25$ memory references per instruction, then the average stall cycles per instruction is ________. answer given is $4$
0 votes
1 answer
3
121 views
Consider the following statements: (i) Accessing of data in a column wise fashion maintains spatial locality only when the block size is equal to the total size of the elements in the row (ii) Coherence in write through protocol never occurs even cache memory is organized in multilevel. Which of the above is true?
0 votes
0 answers
4
201 views
how to approcach such questions please help with all the three statements.