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 .
The goal of this assignment is to give you a chance to feel how simulation works,
how to use a typical simulator. Have fun and good luck!
Run simics on tux machines to simulate execution of the Barnes-Hut benchmark on a simulated 16-processor UltraSPARC2 multiprocessor system. Run the simulation with following input files: input-4K-16 (takes about 4 min), input-4K-8, input-4K-1 (about 25 min), input-1K-16, input-1K-8, input-1K-1 (about 5 min), input-512-16, input-512-8 and input-512-1 (less than 3 min). The first number of the input file name stands for the number of bodies that will be simulated by the Barnes program while the second number of the input file name stands for the number of processors that will take part in the computation.
(A) For each simulated execution, record the total number of instructions executed, the percentage of instructions executed in kernel mode, the total number of memory read and write operations, and the maximum number of execution cycles among the multiple processors that took part in the computation. Represent these statistics numbers neatly in a table.
(B) Draw figures to show the trends from 1 processor to 8, 16 processor configurations for the above statistics. For comparison purpose, draw the trends for 512, 1K and 4K configuration for the same statistics, e.g. the maximum cycles, in the same graph. What trends do you find?
To start with Simics, you should first read documents about simics in the
following directory:
/p/hill/classes/cs757/simics/doc
/mnt/splash2/codes/apps/barnesin the simulated multiprocessor machine to learn what Barnes-Hut bench is and what parameters it needs to simulate the n-body problem. We have some README files in the working directory that guide you what you can do there.
To start with Simics, we provide a step-by-step list below for your reference:
1. Login onto one of the TUX machine, almost the fastest instructional machines available here, and type:
cd /p/hill/classes/cs757/simics/home/barnes
2. Read the README file to see what you can do in this directory. As the first line in README says, you
need to setup the environment variable VTECH_LICENSE_FILE before you can use SimICS. Type:
setenv VTECH_LICENSE_FILE /p/multifacet/projects/simics/dist10/v9-sol7-gcc/sys/flexlm/license.dat
3. Type
./simics -echo -x barnes.simicsto start the simics simulation. You should alos see a new window, which is the console for the simulated machine, appears.
@SIM_cpu_issue_cycles(SIM_proc_no_2_ptr(0))in the SimICS environment.
4. After the simulator comes up, you can issue commands to do your simulation work. In this case, we started a configuration specialized for the Barnes-Hut benchmark from the SPLASH2 suite. Type 'c' or 'run' to let the virtual machine you are simulating continue.
5. Now you have started a simulated 16-processor sparc-solaris machine and you are also in the right directory for Barnes, you are ready to do some real simulations, for example, type:
./BARNES.pthreads.solaris.spin_always.break < input-512-16; /usr/local/magic_call breakin the console for the target(simulated) machine will simulate 512 bodies with 16 virtual processors that are being simulated.
6. Please figure out how to get interesting statistics of your simulated execution, e.g. the number of cycles each processor runs for this workload, the number of instructions, memory operations, etc. The more interesting statistics you get, the better you can use this tool.