Due: Friday Mar 6, 1998 No late homeworks will be accepted
Work in groups of two. Each group should turn in one homework.
Do exercise 5.2 from the text. The measurement program is available here. Turn in a graph of your measurements and for each question, explain your answer and highlight the relevant portion of the graph.
Do exercise 5.5 from the text.
This question involves a uniprocess cache simulator called dinero, present in /u/jingzhao/Courses/CS382M/dinero. An executable version of this simulator is also avaliable in /public/solaris/bin on Computer Science SUN Sparc 5 machines. You will run the simulator on ATUM traces of several programs available on /u/jingzhao/Courses/CS382M/traces/atum. As an example, to run dinero on trace file mul8.003.din.Z, use:
zcat /u/dahlin/public_html/Classes/GradArch/homework/hw3/traces/atum/mul8.003.din.Z | /public/solaris/bin/dinero -options > outfile
where -options is replaces by the specific options you need and outfile is the name of you ouput file. Since the trace files are very large, you do not need to uncompress or copy them. For more information, see dinero's man page.
Run dinero on trace files forf.003.din.Z, mul8.003.din.Z and ue02.000.din.Z to answer the following qestions. Use the dinero default for any cache options not mentioned in the question. Turn in your results and your conclusions.
Examine a 16K-byte, 4-way associative cache with 16-byte blocks. What are the average miss ratios for LRU, FIFO, and random replacement policies? What conclusions can you draw from this experiment?
Compare the cache miss ratios of the following two systems:
Assue the caches are 2-way set associative and the block size is 16 bytes. What conclusions can you draw from this experiment?
Examine a direct-mapped 16K-byte unified cache with 16-byte blocks. What are the miss ratios for the first 100,000 references (reference 1-100,000), the second 100,000 (100,001-200,000), the third 100,000 (200,001-300,000), and the fourth 100,000 (300,001-400,000)? What is the average miss ratio for references 1-400,000? What conclusions can you draw from this experiment? Is running portions of traces a good indication of the overall behavior of a program?
Design an experiment to study some aspect of caches not covered by the above experiments. Describe the experiment, the hypothesis (including the purpose of the experiment, what the results would look like if your hypothesis is false, and what the results would look like if your hypothesis is true), the actual results of running the experiments, and you conclusions. Give an resonable explanation if your results are different from your initial hypothesis.