Simulation is one of the most important research and development methods
in computer architecture. In this assignment, you are provided with an
opportunity to explore with SimICS,
a system level simulator from
Virtutech, as well as Ruby,
a cycle-accurate cache simulator
from Multifacet research
group here at UW-Madison. The goal of this assignment is to give you a
chance to feel how simulation works, how to use a typical simulator and
to get a first-hand feeling about simulation accuracy.
Have fun and good luck!
Before you proceed, please carefully read the Simics tutorial and the Ruby tutorial.
In this assignment, you will modify your shared memory matrix multiply program from homework 1, and study it in depth with a simulator. Let one matrix multiply be called a transaction. Modify your program so that it performs many matrix multiplies (i.e., many transactions). Matrices should be of a fixed sizes but contain data values pseudo-randomly initialized as part of the matrix multiply transaction. Repeatingly performing matrix multiplies will allow you to study a workload in steady state.
(A) Create five different checkpoints that contain a running matrix multiply program that is in steady state (not in initialization or in finishing stage) for systems that have 1, 2, 4, 8, and 16 processors in Simics. Make sure you have properly divided your program into transactions and magic instructions have been properly planted to inform the simulator about the completion for each transaction.
(B) Simulate the matrix multiply program on each system for the same number of transactions. You can simulate any number of transactions you feel comfortable, but try not to simulate too short amount of time for the performance comparison to be meaningful. Collect the cycle number from Simics and plot the scalability curve from 1p to 16p.
(C) Build the Ruby module with the default configuration for the two snooping protocols given (MOSI_bcast_opt and MOSI_directory_opt_blocking_2level). Simulate the matrix multiply program on each system with Ruby enabled. Collect cycle count from Ruby. Plot the scalability curves for the two snooping protocols. Compare and discuss your results from (B) and (C).