※ 引述《a8909132 (shin)》之銘言:
: Memory Problem.
: 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.
Compulsory misses.
The miss rate is proportion to the block size.
In a 64KB direct-mapped cache, there exists 512K / 32 = 16K misses.
: (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?
: I/O Problem.
In 16byte, 512K/16 = 32K.
In 64byte, 512K/64 = 8K.
In 128byte, 512K/128= 4K.
Spatial locality.
: What is the bottleneck in the following system setup, the CPU , memory
: bus, or the disk set?
: 1. The user program continuously performs reads of 64KB blocks, and requires
: 2 million cycles to process each block.
: 2. The operating system requires 1 million cycles of overhead for ezch I/O
: oeration.
: 3. The clock rate is 3GHz.
^CPU^ ??
: 4. The maximum sustained transfer rate of the memory bus is 640MB/sec.
: 5. The read/write bandwidth of the disk controller and the disk drives is
: 64MB/sec, disk average seek plus rotational latency is 9ms.
: 6. There are 20 disks attached to the bus each with its own controller.
: (Assume that each disk can be controlled independently and ignore disk
: conflicts.)
CPU = 3G/3M = 100 IO/second
memory bus = 640MB/64KB=10000 IO/second
1 disk = 1/( 9ms+64KB/64MB) = 1/(9ms+1ms) = 100 IO/second
disk set = 20 * 100 = 2000 IO/second
CPU is the bottleneck.
: 以上問題看張凡講義上的解答看不懂,麻煩請各位高手幫幫忙,在此先說聲謝謝^^
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 59.126.187.85
※ 編輯: privatewind 來自: 59.126.187.85 (09/16 10:42)
※ 編輯: privatewind 來自: 59.126.187.85 (09/16 17:14)