Homework 5
A: Compute the size of RAM
Write a plaform-independent C program
that approximates the size of main memory (RAM).
B: Measure the characteristics of Cache
Write a C program to measure the cache
behavior using Saavadra and Smith's methodology (see below for reference). You will present the
stride/latency graphs and describe the inferred cache parameters. You need
to perform the test on two different machines and present the results.
In your readme, describe the techniques you used to obtain sufficient
accuracy. You might want to use compile optimizations (e.g., -O3) to
prevent loop overhead from biasing the results. However, it might result
in the compiler optimizing away the memory accesses. To avoid this, it's
better to not only compute the sum of values read from the array, but also
to print the final sum.
Article information
- Title: Measuring Cache and TLB Performance and Their Effect on
Benchmark Runtimes.
- Authors: Saavedra, R.H., and A.J. Smith.
- Journal: IEEE Transactions on Computers 44, no. 10 (1995): 1223-1235.
- Link:
http://dx.doi.org/10.1109/12.467697
If accessing from outside Northeastern network, you can use the following
link to get the pdf:
http://ieeexplore.ieee.org.ezproxy.neu.edu/stamp/stamp.jsp?arnumber=467697
Note that this would require you to login using your myNEU credentials.