作者lexa ( )
看板Grad-ProbAsk
标题[理工] [计组] 算出cache的 miss rate
时间Wed Oct 26 14:12:13 2011
Media applications that play audio or video files are part of a class of
workloads called "streaming" workloads; i.e., they bring in large amounts
of data but do not reuse much of it. Consider a video streaming workload
that access a 512KB working set sequentially with the following address stream:
0,4,8,12,16,20,24,28,32, ...
(1)Assume a 64KB direct-mapped cache with a 32-byte line. What is the miss
rate for the address stream above. How is this miss rate sensitive to the
size of the cache or the working set? How would you categorize the misses
this workload is experiencing, based on the 3C model.
(2)Recompute the miss rate when the cache line size is 16 byte , 64 bytes, and
128 bytes? What Kind of locality is this workload exploiting?
答案:
(1)12.5% miss rate. The miss rate doesn’t change with cache size or working
set. These are cold misses.
(2)25%, 6.25% and 3.125% miss rates for 16-byte, 64-byte and 128-byte blocks.
Spatial locality.
我主要是想问第1题12.5%是怎麽算出来的?
--
※ 发信站: 批踢踢实业坊(ptt.cc)
◆ From: 27.105.7.134
※ 编辑: lexa 来自: 27.105.7.134 (10/26 14:15)