Initial commit of OpenSPARC T2 architecture model.
[OpenSPARC-T2-SAM] / sam-t2 / docs / SAMv5userguide1_2.0.html
CommitLineData
920dae64
AT
1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
2<html>
3<head>
4 <meta http-equiv="CONTENT-TYPE"
5 content="text/html; charset=iso-8859-1">
6 <title>/import/archperf-www/Tools/Root_Image.html</title>
7 <meta name="GENERATOR" content="StarOffice 8 (Solaris Sparc)">
8 <meta name="CREATED" content="20030501;15353200">
9 <meta name="CHANGEDBY" content="Sreenivas Vadlapatla">
10 <meta name="CHANGED" content="20070427;14430500">
11 <style>
12 <!--
13 @page { size: 8.5in 11in }
14 -->
15 </style>
16</head>
17<body dir="ltr" lang="en-US">
18<h1 align="center">SAM User Manual</h1>
19<h1 align="center">Version 2.0</h1>
20<p><br>
21<br>
22<br>
23<br>
24<br>
25<br>
26<br>
27<br>
28</p>
29<h1 align="center">Sreenivas Vadlapatla</h1>
30<h1 align="center">Last Updated: 25<sup>th</sup> April 2007</h1>
31<p><br>
32<br>
33<br>
34<br>
35<br>
36<br>
37<br>
38<br>
39</p>
40<h1 align="center"><a
41 name="5.HOWTO: setup run directory scsi init file|outline"></a><a
42 name="5.HOWTO: setup run directory scsi init file|outline"></a>
43Advanced Technology Group</h1>
44<p
45 style="border-style: none none double; border-color: -moz-use-text-color -moz-use-text-color rgb(0, 0, 0); border-width: medium medium 1.1pt; padding: 0in 0in 0.03in; margin-bottom: 0in;">
46<br>
47</p>
48<p
49 style="border-style: none none double; border-color: -moz-use-text-color -moz-use-text-color rgb(0, 0, 0); border-width: medium medium 1.1pt; padding: 0in 0in 0.03in; margin-bottom: 0in;">
50==========================================================================================================================================</p>
51<h1><a name="6.HOWTO: setup run directory fc init file|outline"></a><a
52 name="6.HOWTO: setup run directory fc init file|outline"></a>
53Table of Contents</h1>
54<ol>
55 <li>
56 <p><a href="#8.Purpose%7Coutline"><b><font size="5">Purpose</font></b></a></p>
57 </li>
58 <li>
59 <p><a href="#9.SAM%7Coutline"><b><font size="5">SAM</font></b></a></p>
60 <ol type="a">
61 <li>
62 <p><a href="#SAM%20Huron%7Coutline"><b><font size="5">SAM Huron</font></b></a></p>
63 </li>
64 </ol>
65 </li>
66 <li>
67 <p><a href="#10.SPARC%20CPU%7Coutline"><b><font size="5">SPARC CPU</font></b></a></p>
68 <ol type="a">
69 <li>
70 <p><a href="#Riesling%7Coutline"><b><font size="5">Riesling</font></b></a></p>
71 </li>
72 <li>
73 <p><a href="#Vonk%7Coutline"><b><font size="5">Vonk</font></b></a></p>
74 </li>
75 <li>
76 <p><a href="#Vcpu%20Interface%7Coutline"><b><font size="5">Vcpu
77Interface</font></b></a></p>
78 </li>
79 </ol>
80 </li>
81 <li>
82 <p><a href="#10.Running%20SAM%20Chplus%7Coutline"><b><font size="5">Running
83SAM Chplus</font></b></a></p>
84 <ol type="a">
85 <li>
86 <p><a href="#Getting%20Started%7Coutline"><b><font size="5">Getting
87Started</font></b></a></p>
88 </li>
89 <li>
90 <p><a href="#Creating%20a%20Root%20Image%7Coutline"><b><font
91 size="5">Creating a Root Image</font></b></a></p>
92 </li>
93 <li>
94 <p><a href="#Data%20Disk%20Images%7Coutline"><b><font size="5">Data
95Disk Images</font></b></a></p>
96 </li>
97 <li>
98 <p><a href="#Data%20Disk%20Images%7Coutline"><b><font size="5">Getting
99and running SAM</font></b></a></p>
100 </li>
101 <li>
102 <p><a href="#RC%20file%20Setup%7Coutline"><b><font size="5">RC
103file Setup</font></b></a></p>
104 </li>
105 <li>
106 <p><a href="#SCSI%20init%20file%20Setup%7Coutline"><b><font
107 size="5">SCSI init file Setup</font></b></a></p>
108 </li>
109 <li>
110 <p><a href="#FC%20init%20file%20Setup%7Coutline"><b><font
111 size="5">FC init file Setup</font></b></a></p>
112 </li>
113 <li>
114 <p><a
115 href="#Disk%20Image%20file%20from%20a%20Reference%20System%7Coutline"><b><font
116 size="5">Disk Image file from a Reference System</font></b></a></p>
117 </li>
118 <li>
119 <p><a
120 href="#Modifying%20root%20image%20to%20boot%20on%20SAM%7Coutline"><b><font
121 size="5">Modifying root image to boot on SAM</font></b></a></p>
122 </li>
123 <li>
124 <p><a href="#Check-pointing%20using%20Dump/Restore%7Coutline"><b><font
125 size="5">Check-pointing using Dump/Restore</font></b></a></p>
126 <ul>
127 <li>
128 <p><a href="#Lazy%20Restore%7Coutline"><b><font size="5">Lazy
129Restore</font></b></a></p>
130 </li>
131 </ul>
132 </li>
133 </ol>
134 </li>
135 <li>
136 <p><a href="#11.Running%20SAM%20Huron%7Coutline"><b><font size="5">Running
137SAM Huron</font></b></a></p>
138 <ol type="a">
139 <li>
140 <p><a href="#Getting%20and%20running%20SAM%20Huron%7Coutline"><b><font
141 size="5">Getting and running SAM Huron</font></b></a></p>
142 </li>
143 <li>
144 <p><a href="#Huron%20RC%20file%20Setup%7Coutline"><b><font
145 size="5">Huron RC file Setup</font></b></a></p>
146 </li>
147 <li>
148 <p><a
149 href="#Modifying%20root%20image%20to%20boot%20on%20SAM%20Huron%7Coutline"><b><font
150 size="5">Modifying root image to boot on SAM Huron</font></b></a></p>
151 </li>
152 </ol>
153 </li>
154 <li>
155 <p><a href="#12.Tracing%7Coutline"><b><font size="5">Tracing</font></b></a></p>
156 <ol type="a">
157 <li>
158 <p><a href="#Trace%20Collection%20and%20Validation%7Coutline"><b><font
159 size="5">Trace Collection and Validation</font></b></a></p>
160 </li>
161 </ol>
162 </li>
163 <li>
164 <p><a href="#14.HOWTOs%7Coutline"><b><font size="5">HOWTOs</font></b></a></p>
165 <ol type="a">
166 <li>
167 <p><a href="#Open%20extra%20Console%20Windows%7Coutline"><b><font
168 size="5">Open extra Console Windows</font></b></a></p>
169 </li>
170 </ol>
171 </li>
172</ol>
173<p><font size="4">================================================================================================================</font></p>
174<h1><a name="8.Purpose|outline"></a>Purpose</h1>
175<p>The purpose of this document is to create a &#8220;cook book&#8221;
176for SAM setup and tracing. This document will go over all the
177necessary steps on how to get SAM up and running so you can start
178tracing. Also note that SAM and blaze refer to the same thing and are
179used interchangeably in this document. The document describes SAM and
180it's features followed by descriptions on how to run SAM. Tracing and
181validation guidelines are explained in great detail followed by
182execution driven simulation. SAM combined with ValueSim can be hooked
183up to a cycle accurate simulator and used in execution driven mode.</p>
184<p>==========================================================================================================================================</p>
185<h1><a name="9.SAM|outline"></a>SAM</h1>
186<p>SAM is a full system (CPU, memory, network, hard disk, timer)
187simulator developed at SUN and currently maintained by the Advanced
188Technology group (ATG). It simulates various SPARC V9-based systems
189running the Solaris operating system. It is primarily used for
190collecting architectural traces from workloads such as TPCC, SPECWeb,
191ICPERF, SPECJAppServer, ICPERF, SPECJbb, SPEC CPU, etc. SAM is also
192being used in RTL verification and in system bringup. It boots a fake
193boot prom or Sun-Fire OBP, and then the real OS. Since SAM-v5 runs
194off-the-shelf OS, most high-level functionality built on top is
195available in the simulation including TCP/IP, file systems, kernel
196modules, multiple-users, NIS, etc.</p>
197<p>SAM simulates a system consisting of the following:</p>
198<ul>
199 <li>
200 <p>One or more SPARC CPUs.</p>
201 </li>
202 <li>
203 <p>Physical memory (RAM)</p>
204 </li>
205 <li>
206 <p>Bridge</p>
207 </li>
208 <li>
209 <p>Switch</p>
210 </li>
211 <li>
212 <p>A serial console device</p>
213 </li>
214 <li>
215 <p>The disk subsystem (e.g. SCSI or FibreChannel)</p>
216 </li>
217 <li>
218 <p>The network cards (e.g. gem or cassini)</p>
219 </li>
220</ul>
221<p>SAM-v5 is a new SAM revision with enhanced user interface for
222system configuration and new expandable and flexible infrastructure.
223Note that some devices are system specific and so are modeled
224accordingly and used in that particular SAM system. Further details
225in the sections that follow.</p>
226<p>---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------</p>
227<h2>SAM Huron</h2>
228<p>SAM-Huron (Sun Fire T2000) system configuration uses the Niagara
229(UltraSPARC-T2) chip as the CPU. SAM Huron consists of SAM system
230simulator plus the <a href="#Vonk%7Coutline">Vonk</a> processor
231reference model. The following is the component list of modules in
232SAM Huron:</p>
233<ul>
234 <li>
235 <p>Vonk &#8211; Niagara 2 Processor Model</p>
236 </li>
237 <li>
238 <p>PCIE-PCIE Switch</p>
239 </li>
240 <li>
241 <p>PCIE-PCI Bridge</p>
242 </li>
243 <li>
244 <p>SCSI Controller</p>
245 </li>
246 <li>
247 <p>FC Controller</p>
248 </li>
249 <li>
250 <p>SCSI Disk</p>
251 </li>
252 <li>
253 <p>FC Disk</p>
254 </li>
255 <li>
256 <p>Networking &#8211; GE/CE/E1000g adapters</p>
257 </li>
258 <li>
259 <p>Miscellaneous &#8211; LL, RTC, Serial etc. </p>
260 </li>
261</ul>
262<p>For further details please refer to
263<a
264 href="https://systemsweb.sfbay.sun.com/archperf/TOI/talk-2007/qe-sam-toi.odp">https://systemsweb.sfbay.sun.com/archperf/TOI/talk-2007/qe-sam-toi.odp</a></p>
265<p>---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------</p>
266<p>==========================================================================================================================================</p>
267<h1><a name="10.SPARC CPU|outline"></a>SPARC CPU</h1>
268<p>We have the following four SPARC CPU models currently modelled in
269SAM:</p>
270<ul>
271 <li>
272 <p>Niagara II, Huron Systems (Vonk N2)</p>
273 </li>
274</ul>
275<p>---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------</p>
276<h2><a name="Riesling|outline"></a><a name="Riesling|outline"></a>Riesling/Vonk</h2>
277<p>Riesling is the SPARC CPU architecture model in the SAM Ontario
278(T1) full-system simulator. Vonk is used for both Niagara II and ROCK
279CPU models. Vonk N2 is the SPARC CPU architecture model in the SAM
280Huron (T2) full-system simulator. Vonk ROCK is the SPARC CPU
281architecture model in the SAM Supernova full-system simulator.
282Riesling/Vonk is the overall name for the Sun UltraSPARC processor
283golden reference model product, it implements the full UltraSPARC
284architecture specification. On top of the UltraSPARC specification,
285Riesling/Vonk implements the deltas from that specification as
286mentioned in each product specific PRM (Programming Reference
287Manual), but usually only the parts that are related to processor
288functions. </p>
289<p>Riesling/Vonk always implements a full system model in turn of CPU
290architecture. A Riesling/Vonk system consists of a number of
291Riesling/Vonk CPUs. A Riesling/Vonk CPU consists of a number of
292Riesling/Vonk cores. A Riesling/Vonk core consists of a number of
293Riesling/Vonk strands. The structure and functionality of the
294Riesling/Vonk system that is provided in the Riesling/Vonk library
295reflects the hardware it functionally models. Riesling/Vonk also
296provides a simple memory model. A system is a combination of CPU
297model(s) and memory model(s). Together the CPU models and memory
298model(s) in the Riesling/Vonk library allow for a standalone
299simulator of CPUs with memory to be built out of the box.
300Riesling/Vonk itself does not provide device model functionality. </p>
301<p>Riesling/Vonk does not model time. A single step (cycle) in
302Riesling/Vonk means: Fetch, Decode, Execute, and Retire the
303architectural state, in one single operation. In essence,
304Riesling/Vonk is a functional simulator, it does not provide any
305performance indication of the modeled CPU architecture. Caches are
306not modeled in Riesling/Vonk. Caches are functionally not required by
307the UltraSPARC specification. This means that cache coherency is also
308not modeled in Riesling/Vonk. Riesling/Vonk generally does not model
309functions related to errors and diagnostics. However, some functions
310related to those areas are implemented due to special modeling
311requirements. </p>
312<p>Riesling/Vonk library is a collection of C++ classes. The classes
313are constructed in a way that mimics hardware structure. For
314Riesling, default UltraSPARC Ontario system configuration (one CPU,
315eight cores per CPU, four strands per core) is implemented in the
316library, users have the capability to extend the classes to create
317their own T1-like systems. For Vonk N2, default UltraSPARC Huron
318system configuration (one CPU, eight cores per CPU, eight strands per
319core) is implemented in the library, users have the capability to
320extend the classes to create their own T2-like systems.</p>
321<p>---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------</p>
322<h2><a name="Vcpu Interface|outline"></a>Vcpu Interface</h2>
323<p>Vcpu hides the details of the cpu specific implementation. It
324presents an abstract interface to the "virtual cpu".</p>
325<ul>
326 <li>
327 <p>for cpu with multiple strands it represents each strands</p>
328 </li>
329</ul>
330<ul>
331 <li>
332 <p>for cpu without strands it represent the cpu</p>
333 </li>
334</ul>
335<p>Vcpu interface has a few components:</p>
336<ul>
337 <li>
338 <p>control interface</p>
339 </li>
340 <li>
341 <p>system interface ( Memory and IO )</p>
342 </li>
343 <li>
344 <p>trace interface</p>
345 </li>
346</ul>
347<p>For further details on usage and other features refer to
348<a
349 href="https://systemsweb.sfbay.sun.com/archperf/TOI/Oct2006/VcpuInterface.html">https://systemsweb.sfbay.sun.com/archperf/TOI/Oct2006/VcpuInterface.html</a></p>
350<p>==========================================================================================================================================</p>
351<h1><a name="10.Running SAM Chplus|outline"></a>Running SAM Chplus</h1>
352<p>To run SAM, launch the SAM binary from the SAM run directory.
353Ofcourse before running SAM Chplus we need a solaris root image,
354configuration files etc. The following sections explain in detail the
355steps that need to be done. Most of the steps are common to running
356SAM irrespective of whether it is SAM Chplus or SAM Huron etc.</p>
357<p>---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------</p>
358<h2><a name="Getting Started|outline"></a><a
359 name="Getting Started|outline"></a>
360Getting Started</h2>
361<p>You will need at least Solaris 2.8 and above with at least 512 MB
362of RAM on each machine. However, to simulate machine the host side
363would consume about &frac34;<sup>th</sup> of the total memory size.
364So, size accordingly. Some planning and set-up is necessary before
365running SAM. This involves specifying the system configuration,
366setting up all necessary input files, and making sure the host
367machine and the working directory on which the simulation is run are
368adequate for the task. <br>
369<br>
370There are two principle ways to run
371SAM: restore from a pre-existing checkpoint, and start a fresh run
372from scratch. Most often, you will restore from existing checkpoints
373in order to collect traces or run simulations. Restoring from a
374checkpoint is easiest because the system configuration is
375pre-determined and you simply need to sym-link or copy over the
376necessary files into the working directory before running the
377simulation. For a run from scratch, it is advisable to start with an
378existing configuration as a template, and modify the necessary
379configuration parameters (such as cpu count and frequency, device
380hierarchy etc.). When restoring from a checkpoint, there are other
381considerations that apply (see Lazy Restore).<br>
382<br>
383In both cases,
384the system-configuration file (usually called config.rc) is a good
385starting point. This file specifies the type and number of simulated
386CPUs, the amount of simulated memory, the number of simulated
387devices, pointers to the mapping of real disk images to simulated
388disks etc. This file also specifies the number of host threads onto
389which the simulated CPUs are mapped. You should always ensure that
390the number of host threads used is at least equal to the number of
391real available CPUs on the host system. Furthermore, some
392applications like execution-driven simulation may require a single
393host thread for all the simulated CPUs. <br>
394<br>
395By default, SAM will
396try to allocate as much real memory as the simulated RAM. If you
397decide to go with this default, ensure that the host machine has
398enough RAM+SWAP (and also enough free swap) to accommodate this
399amount. It is possible to map simulated memory to a disk file rather
400than physical memory, in which case you need to allow enough space in
401the working directory for the memory-mapped file. When the simulated
402application writes to the simulated disks, the updates are written to
403files called "overlays" in the working directory. You need
404to anticipate the needs of the program and allow enough free space in
405the working directory for the overlays. <br>
406<br>
407For example, if the
408simulated application is a database that performs 1000 writes of 8KB
409per simulated second and you are simulating 1200 seconds, you need
410enough space for 1.2M updates, or 1.2M x 8KB = 9.6 GB of free space
411for overlays. <br>
412<br>
413The latest release is in
414/import/archperf/pkgs/sam/latest</p>
415<p>For insturctions on how to bringover sam and build it yourself
416refer to: <a href="#Getting%20and%20running%20SAM%7Coutline">Getting
417and
418running SAM</a></p>
419<p>For the list of files needed for SAM Chplus run directory refer
420to: <a href="#Getting%20and%20running%20SAM%7Coutline">Getting and
421running
422SAM</a></p>
423<p>---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------</p>
424<h2><a name="Creating a Root Image|outline"></a><a
425 name="Creating a Root Image|outline"></a>
426Creating a Root Image</h2>
427<p>You will need to do serveral steps to create the root image before
428running Blaze. Also, you will need to login as root before
429proceeding. Note that root.img and swap.img are part of the file list
430needed to run SAM. </p>
431<p>For further details on creating a root image refer to: <a
432 href="#HOWTO:%20create%20a%20root%20disk%20image%20file%20from%20a%20reference%20system%7Coutline">#HOWTO:
433create a root disk image file from a reference system|outline</a></p>
434<p>When we use fakeprom to build the SAM device tree we need to make
435modifications to the root image and for details on modifying the root
436image refer to: <a
437 href="#HOWTO:%20modify%20reference%20root%20image%20into%20SAM%20root%20image%7Coutline">#HOWTO:
438modify reference root image into SAM root image|outline</a></p>
439<p>When you modify root image you will notice a driver by name ll
440being loaded. This driver is used to give access to local host file
441system from SAM simulated environment.</p>
442<p>Blaze supports LLFS (localhost lookup file system) letting you
443read/write files on your host machine directly from the simulated
444host. Thus, the simhost can access /import/arch-trace25,
445/import/arch-trace30/ and /tmp/logman on your host. More importantly,
446LLFS lets you run SAM as a user program and have access to all NFS
447files on SWAN, which is where your benchmark programs probably
448reside. </p>
449<p>We map / on the host to /ll/root in simhost via LLFS. E.g. to
450access your home directory from /home/xyz. You would go to
451/ll/root/home/xyz in SAM. </p>
452<p>As a added convenience, we (use symbolic links to) map the
453following directories in the sim host to the same directory on the
454underlying host: </p>
455<p>/home, /net, /vol, /ws, /import, /usr/ccs, /usr/share,
456/usr/shared, /usr/dist</p>
457<p>Thus, in the simhost, you can get to your home directory via
458/home/xyz as well as /ll/root/home/xyz. Tycho wrote the nifty LLFS
459(local lookup file system). Tycho implemented LLFS correctly, by
460implementing the Solaris LL file system, the Solaris LL device driver
461and the LL device (in SAM). /home /net /vol /ws /import /usr/ccs
462/usr/share /usr/shared /usr/dist.</p>
463<p>---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------</p>
464<h2><a name="Data Disk Images|outline"></a><a
465 name="Data Disk Images|outline"></a><a name="Data Disk Images|outline"></a>
466Data Disk Images</h2>
467<p>We use the same dd procedure for collecting data disk images. The
468database disks can be under SVM (Solaris Volume Manager) or under
469Veritas. For SVM you can use metadb to get a listing. For Veritas you
470can use vxprint to get a list of all disks under Veritas. You can
471then select the disks you want to take disk images of i.e. only those
472belonging to the database of interest.</p>
473<p>For information on setting scsidisk.init with respect to SVM and
474Veritas refer to: <a href="#SCSI%20init%20file%20Setup%7Coutline">SCSI
475init
476file Setup</a></p>
477<p>For information on setting fcdisk.init with respect to SVM and
478Veritas refer to: <a href="#FC%20init%20file%20Setup%7Coutline">FC
479init file
480Setup</a></p>
481<p>Also during root image modification note that SVM requires
482/etc/path_to_inst file entries for the database disks. The disks
483should also have the same minor numbers as they had on the host
484reference machine. For further details on this refer to: <a
485 href="#HOWTO:%20modify%20reference%20root%20image%20into%20SAM%20root%20image%7Coutline">#HOWTO:
486modify reference root image into SAM root image|outline</a></p>
487<p>---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------</p>
488<h2><a name="Getting and running SAM|outline"></a><a
489 name="Getting and running SAM|outline"></a>
490Getting and running SAM</h2>
491<p>Go to the directory where you want the SAM to be installed and run
492the following command. Note that SAM chplus, SAM vonk etc. are all in
493one workspace.</p>
494<p><i><b># bringover -p /import/archperf/ws/sam -w ./&lt;samdir&gt; .</b></i></p>
495<p><i><b># cd &lt;samdir&gt;</b></i></p>
496<p><i><b># make install-chplus</b></i></p>
497<p style="font-style: normal;">The above command
498will build the Chplus version of SAM. Similarly you can build for N2
499using make install-n2 command. Refer to Makefile.targetspecs for a
500list of all target builds. The above command will create a directory
501install-chplus. You will find the following directories under
502install-chplus directory: bin, doc, etc, lib, man, pfe, rtl. The bin
503directory has the sam binary and the lib directory has all the
504loadable modules for devices. </p>
505<p style="font-style: normal;">Before you can run
506SAM the run directory must contain the following files:</p>
507<ol>
508 <li>
509 <p><font face="Thorndale, serif"><font size="3"><b>bin/sam:</b> sam
510binary</font></font></p>
511 </li>
512 <li>
513 <p><font face="Thorndale, serif"><font size="3"><b>lib/*.so:</b>
514the lib directory contains all the loadable modules (*.so)</font></font></p>
515 </li>
516 <li>
517 <p><font face="Thorndale, serif"><b>config.rc:</b> the rc file
518where system configuration is specified. </font><a
519 href="#RC%20file%20Setup%7Coutline">RC file Setup</a></p>
520 </li>
521 <li>
522 <p><font face="Thorndale, serif"><b>scsidisk.init:</b> there could
523be more than one of these files. </font><a
524 href="#SCSI%20init%20file%20Setup%7Coutline">SCSI init file Setup</a></p>
525 </li>
526 <li>
527 <p><font face="Thorndale, serif"><b>fcdisk.init:</b> there could be
528more than one of these files. </font><a
529 href="#FC%20init%20file%20Setup%7Coutline">FC init file Setup</a></p>
530 </li>
531 <li>
532 <p><b>fakeprom or samprom:</b> this file is needed when we use the
533fakeprom device tree (only used in sam chplus based systems), not
534needed if we boot using OBP</p>
535 </li>
536 <li>
537 <p><b>ufsboot:</b> this file has to be copied from the root image
538/tmp/root-image/platform/sun4u/ufsboot</p>
539 </li>
540 <li>
541 <p><b>root.img:</b> link to or a copy of the modified root image. <a
542 href="#Disk%20Image%20file%20from%20a%20Reference%20System%7Coutline">Disk
543Image file from a Reference System</a></p>
544 </li>
545 <li>
546 <p><b>swap.img:</b> link to or a copy of swap image. <a
547 href="#Disk%20Image%20file%20from%20a%20Reference%20System%7Coutline">Disk
548Image file from a Reference System</a></p>
549 </li>
550</ol>
551<p><font color="#000000"><font face="Thorndale, serif"><font size="3"><u><b>Without
552networking:</b></u></font></font></font></p>
553<p><font color="#000000"><font face="Thorndale, serif"><font size="3"><i><b>#
554bin/sam -w -c config.rc</b></i></font></font></font></p>
555<p><font color="#000000"><font face="Thorndale, serif"><font size="3">The
556-w automatically brings up the console window of the simulated
557machine. Make sure you have set your DISPLAY environment variable
558correctly.</font></font></font></p>
559<p><font color="#000000"><font face="Thorndale, serif"><font size="3">At
560blaze prompt: run</font></font></font></p>
561<p><font color="#000000"><font face="Thorndale, serif"><font size="3"><u><b>With
562networking:</b></u></font></font></font></p>
563<p><font color="#000000"><font face="Thorndale, serif"><font size="3">Make
564sure you have created a file called hostname.ge0 in /etc/system
565directory on root image and the file should have the machine name in
566it.</font></font></font></p>
567<p><font color="#000000"><font face="Thorndale, serif"><font size="3">It
568could be ge0 or ce0 depending the NIC card gem or cassini being used.
569It could be ge0 or ge1 depending on the name specified in rc file for
570the device.</font></font></font></p>
571<ol>
572 <li>
573 <p><font color="#000000"><font face="Thorndale, serif"><font
574 size="3">Start switchsim on any machine using command: <b><i>#
575/import/blaze-trace/blz-binaries/switch-v1.6 -r ip</i></b>. Switch does
576the following:</font></font></font></p>
577 <ol>
578 <ol type="a">
579 <li>
580 <p><font color="#000000"><font face="Thorndale, serif"><font
581 size="3">connects multiple blaze simulated environments together</font></font></font></p>
582 </li>
583 <li>
584 <p><font color="#000000"><font face="Thorndale, serif"><font
585 size="3">models network delay</font></font></font></p>
586 </li>
587 <li>
588 <p><font color="#000000"><font face="Thorndale, serif"><font
589 size="3">sync multiple blazes on time boundaries</font></font></font></p>
590 </li>
591 <li>
592 <p><font color="#000000"><font face="Thorndale, serif"><font
593 size="3">behaves as a traditional switch in a real network</font></font></font></p>
594 </li>
595 </ol>
596 </ol>
597 </li>
598 <li>
599 <p><font color="#000000"><font face="Thorndale, serif"><font
600 size="3">Start blaze and connect to switch</font></font></font></p>
601 </li>
602</ol>
603<pre style="margin-left: 0.5in;"><i><b># bin/sam -w -c config.rc</b></i>
604At blaze prompt: &#8220;simge connect &lt;machine name&gt;&#8221; where &lt;machine name&gt; is the machine on which switchsim is running
605At blaze prompt: &#8220;sync connect &lt;machine name&gt;&#8221; where &lt;machine name&gt; is the machine on which switchsim is running
606<font color="#000000"><font face="Cumberland, monospace"><font size="2">At blaze prompt: &#8220;conf&#8221; ensure correct values for all parameters, if not, change using &#8220;conf &lt;parameter&gt; &lt;value&gt;&#8221;</font></font></font>
607<font color="#000000"><font face="Cumberland, monospace"><font size="2">At blaze prompt: run</font></font></font></pre>
608<ol start="3">
609 <li>
610 <pre style="margin-bottom: 0.2in;"><font color="#000000"><font
611 face="Thorndale, serif"><font size="3">Bringup ge/ce NIC</font></font></font></pre>
612 </li>
613</ol>
614<pre style="margin-left: 0.5in;">After boot login as root in the simulated machine and then run the following commands in the simulated machine:<br>devfsadm -i ge<br>ifconfig ge0 plumb<br>ifconfig ge0 inet &lt;ip address&gt; netmask &lt;net mask&gt;<br>ifconfig ge0 ether &lt;mac address&gt;, mac address is currently not being used in SAM<br>ifconfig ge0 up</pre>
615<ol start="4">
616 <li>
617 <p>Start other blazes and connect them using steps 2 and 3 above.</p>
618 </li>
619 <li>
620 <p>Check to see if the simulated machines are communicating using
621traditional ping etc.</p>
622 </li>
623</ol>
624<p>---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------</p>
625<h2><a name="RC file Setup|outline"></a><a name="RC file Setup|outline"></a><a
626 name="RC file Setup|outline"></a>
627RC file Setup</h2>
628<p><font color="#000000"><font face="Thorndale, serif"><font size="3">Here
629is a sample TPCC rc file. I included TPCC because it covers all the
630facets of the setup.</font></font></font></p>
631<pre>############################################### start of rc file ###########################################################<br><br>conf ramsize 65536M<br><br>conf mmutype cheetahplus<br><br>conf bootpath /pci@1f,600000/scsi@1/disk@d,0:a<br><br>conf cpu_per_thread 1<br><br>conf stickfreq 12500000<br><br>load 0x0e00000 fakeprom 0xffd00000<br>load 0x00120000 ufsboot 0x00120000<br><br>write word 0x00 0x120000<br>write word 0x04 0x120000<br>write word 0x08 0x34ffff<br>write word 0x0c 0x120000<br>write word 0x10 0x2<br>write word 0x38 0x1234<br>write byte 0x3c 0x80<br><br>sysconf -p ./<br><br>sysconf cpu name=cpu0 cpu-type=SUNW,UltraSPARC-III+ clock-frequency=3000000000 dtlb-entries=32 itlb-entries=32<br>sysconf cpu name=cpu1 cpu-type=SUNW,UltraSPARC-III+ clock-frequency=3000000000 dtlb-entries=32 itlb-entries=32<br>sysconf cpu name=cpu2 cpu-type=SUNW,UltraSPARC-III+ clock-frequency=3000000000 dtlb-entries=32 itlb-entries=32<br>sysconf cpu name=cpu3 cpu-type=SUNW,UltraSPARC-III+ clock-frequency=3000000000 dtlb-entries=32 itlb-entries=32<br>sysconf cpu name=cpu4 cpu-type=SUNW,UltraSPARC-III+ clock-frequency=3000000000 dtlb-entries=32 itlb-entries=32<br>sysconf cpu name=cpu5 cpu-type=SUNW,UltraSPARC-III+ clock-frequency=3000000000 dtlb-entries=32 itlb-entries=32<br>sysconf cpu name=cpu6 cpu-type=SUNW,UltraSPARC-III+ clock-frequency=3000000000 dtlb-entries=32 itlb-entries=32<br>sysconf cpu name=cpu7 cpu-type=SUNW,UltraSPARC-III+ clock-frequency=3000000000 dtlb-entries=32 itlb-entries=32<br><br>conf mips 300<br><br>setreg pc 0xe00020<br>setreg npc 0xe00024<br><br>sysconf excalibur excalibur0<br><br>sysconf pci_bus pciA31 bridge=schizo31 -d0<br>sysconf pci_bus pciB31 bridge=schizo31 -d0<br>sysconf pci_bus pciA30 bridge=schizo30 -d0<br>sysconf pci_bus pciB30 bridge=schizo30 -d0<br>sysconf pci_bus pciA29 bridge=schizo29 -d0<br>sysconf pci_bus pciB29 bridge=schizo29 -d0<br>sysconf pci_bus pciA28 bridge=schizo28 -d0<br>sysconf pci_bus pciB28 bridge=schizo28 -d0<br><br>sysconf schizo schizo31 aid=31 pciA=pciA31 pciB=pciB31 -d0<br>sysconf schizo schizo30 aid=30 pciA=pciA30 pciB=pciB30 -d0<br>sysconf schizo schizo29 aid=29 pciA=pciA29 pciB=pciB29 -d0<br>sysconf schizo schizo28 aid=28 pciA=pciA28 pciB=pciB28 -d0<br><br>sysconf scsi scsi0 bus=pciA31 schizo=schizo31 dev=1 targets=scsidisk.init boothba -d0<br><br>sysconf rtc rtc0 bus=pciA31 dev=3 fun=0 <br><br>sysconf gem ge1 bus=pciB31 dev=4 fun=0 <br><br>sysconf serial console bus=pciB31 dev=5 fun=0 sam-console<br><br>sysconf ll PBBll bus=pciB31 dev=6 fun=0 <br><br>sysconf fc PBBfc01 bus=pciA30 schizo=schizo30 dev=1 targets=fcdisk1.multi1.init<br>sysconf fc PBBfc02 bus=pciA30 schizo=schizo30 dev=2 targets=fcdisk1.multi2.init<br>sysconf fc PBBfc03 bus=pciA30 schizo=schizo30 dev=3 targets=fcdisk1.multi3.init<br>sysconf fc PBBfc04 bus=pciA30 schizo=schizo30 dev=4 targets=fcdisk1.multi4.init<br>sysconf fc PBBfc05 bus=pciB30 schizo=schizo30 dev=5 targets=fcdisk1.multi5.init<br>sysconf fc PBBfc06 bus=pciB30 schizo=schizo30 dev=6 targets=fcdisk1.multi6.init<br>sysconf fc PBBfc07 bus=pciB30 schizo=schizo30 dev=7 targets=fcdisk1.multi7.init<br>sysconf fc PBBfc08 bus=pciB30 schizo=schizo30 dev=8 targets=fcdisk1.multi8.init<br><br>sysconf fc PBBfc09 bus=pciA29 schizo=schizo29 dev=1 targets=fcdisk1.multi9.init<br>sysconf fc PBBfc10 bus=pciA29 schizo=schizo29 dev=2 targets=fcdisk2.multi1.init<br>sysconf fc PBBfc11 bus=pciA29 schizo=schizo29 dev=3 targets=fcdisk2.multi2.init<br>sysconf fc PBBfc12 bus=pciA29 schizo=schizo29 dev=4 targets=fcdisk2.multi3.init<br>sysconf fc PBBfc13 bus=pciB29 schizo=schizo29 dev=5 targets=fcdisk2.multi4.init<br>sysconf fc PBBfc14 bus=pciB29 schizo=schizo29 dev=6 targets=fcdisk2.multi5.init<br>sysconf fc PBBfc15 bus=pciB29 schizo=schizo29 dev=7 targets=fcdisk2.multi6.init<br>sysconf fc PBBfc17 bus=pciB29 schizo=schizo29 dev=8 targets=fcdisk2.multi7.init<br><br>sysconf fc PBBfc18 bus=pciA28 schizo=schizo28 dev=1 targets=fcdisk2.multi8.init<br>sysconf fc PBBfc19 bus=pciA28 schizo=schizo28 dev=2 targets=fcdisk3.multi1.init<br>sysconf fc PBBfc20 bus=pciA28 schizo=schizo28 dev=3 targets=fcdisk3.multi2.init<br>sysconf fc PBBfc21 bus=pciA28 schizo=schizo28 dev=4 targets=fcdisk3.multi3.init<br>sysconf fc PBBfc22 bus=pciB28 schizo=schizo28 dev=5 targets=fcdisk3.multi4.init<br>sysconf fc PBBfc23 bus=pciB28 schizo=schizo28 dev=6 targets=fcdisk3.multi5.init<br>sysconf fc PBBfc24 bus=pciB28 schizo=schizo28 dev=7 targets=fcdisk3.multi6.init<br>sysconf fc PBBfc25 bus=pciB28 schizo=schizo28 dev=8 targets=fcdisk3.multi7.init<br><br>sysconf fc PBBfc26 bus=pciB31 schizo=schizo31 dev=8 targets=fcdisk3.multi8.init<br><br>console-send "kernel/sparcv9/unix -vV\n"<br><br>################################################### end of rc file ###########################################################</pre>
632<p><br>
633<br>
634</p>
635<p><font face="Thorndale, serif">Here is an explanation of each of
636the above lines:</font></p>
637<pre><b>conf ramsize 65536M</b> &#8211; size of RAM or Memory on simulated machine<br><br><font
638 face="Cumberland, monospace"><font size="2"><b>conf mmutype cheetahplus</b> &#8211; mmu type for simulated machine</font></font>
639
640<b>conf bootpath /pci@1f,600000/scsi@1/disk@d,0:a</b> &#8211; specifies the path of the boot device (root image), in this case c1t13d0s0<br><br><b>conf cpu_per_thread 1</b> &#8211; blaze is a multi-threaded (MP-on_MP) application. In this case the rc file specifies 8 cpus and the <br>cpu_per_thread of 1 means blaze creates 8 threads for 8 cpus i.e. 1 thread to handle each cpu. If the cpu_per_thread value <br>were 2 blaze will create 4 threads to handle 8 cpus i.e. 2 cpus per thread. Apart from the cpu threads blaze creates 1 thread <br>per disk controller (scsi and/or fc). The UI in blaze runs on a separate thread.<br><br><b>conf stickfreq 12500000</b> &#8211; run the binary /home/vsreeni/bin/stick on the reference machine and the output is the stick frequency.<br>Solaris uses STICK and STICK_COMPARE registers to keep track of time. stickfreq value defines the frequency at which the STICK<br>register update happens.<br><br><b>load 0x0e00000 fakeprom 0xffd00000</b> &#8211; where 0xffd00000 is the start adress in fakeprom (always verify this using <br>dis fakeprom, if different then change this. Fakeprom is loaded at address 0x0e00000 in memory of simulated machine.<br><br><b>load 0x00120000 ufsboot 0x00120000</b> &#8211; explanation same as for fakeprom. Just as for fakeprom you need to verify <br>start address of ufsboot by doing dis ufsboot.<br><br><b>sysconf -p ./</b> - indicates the directory in which the loadable modules are present in this case ./ i.e. current directory. In <br>latest blaze I think this is not changeable i.e. the search path for loadable modules is hard-coded to ./lib<br><br><b>sysconf cpu name=cpu0 cpu-type=SUNW,UltraSPARC-III+ clock-frequency=3000000000 dtlb-entries=32 itlb-entries=32</b> &#8211; cpu specification<br><br><b>conf mips 300</b> &#8211; Make sure this conf line is always specified after the cpu specification lines in the rc file. Useful in cpi <br>calculation. CPI is calculated by the formula: CPU clock frequency in Mhz / mips. For example in the above rc file the CPI will be<br>3000 / 300 = 10.<br><br><b>setreg pc 0xe00020</b> &#8211; this does not change unless for some reason fakeprom had to be loaded at an address different from 0x0e00000 <br>in memory of simulated machine <br><br><b>setreg npc 0xe00024</b> &#8211; explanation same as for setreg pc above.<br><br><font
641 face="Cumberland, monospace"><font size="2"><b>sysconf excalibur excalibur0</b> &#8211; loading of excalibur module</font></font>
642
643<b>sysconf pci_bus pciA31 bridge=schizo31 -d0</b> &#8211; pci bus specification and the bridge it is attached. -d0 specifies the debug level.<br><br><b>sysconf schizo schizo31 aid=31 pciA=pciA31 pciB=pciB31 -d0</b> &#8211; specification for schizo bridge chip and the names of pci buses <br>attached to the bridge.<br><br><b>sysconf scsi scsi0 bus=pciA31 schizo=schizo31 dev=1 targets=scsidisk.init boothba -d0</b> &#8211; specification for scsi controller, states <br>that scsi controller scsi0 is on bus pciA31 of schizo31 bridge chip. All the disks attached to this controller are specified in <br>scsidisk.init. <a
644 href="#5.HOWTO:%20setup%20run%20directory%20scsi%20init%20file%7Coutline">#5.HOWTO: setup run directory scsi init file|outline</a>
645
646<b>sysconf rtc rtc0 bus=pciA31 dev=3 fun=0</b> &#8211; specification for real time clock device module<br><br><b>sysconf gem ge1 bus=pciB31 dev=4 fun=0</b> &#8211; specification for gem device module which is ethernet card<br><br><b>sysconf serial console bus=pciB31 dev=5 fun=0 sam-console</b> &#8211; specification for serial console, the console of the simulated machine<br><br><b>sysconf ll PBBll bus=pciB31 dev=6 fun=0</b> &#8211; specification for access to local file system, ll module<br><br><b>sysconf fc PBBfc01 bus=pciA30 schizo=schizo30 dev=1 targets=fcdisk1.multi1.init</b> &#8211; similar to scsi controller this is a <br>specification fc controller PCCfc01 which is attached to bus pciA30 of schizo30 bridge chip. The fc disks attached to this <br>controller are in fcdisk1.multi1.init. <a
647 href="#6.HOWTO:%20setup%20run%20directory%20fc%20init%20file%7Coutline">#6.HOWTO: setup run directory fc init file|outline</a>
648
649There can be a maximum of 8 devices attached to each bus of schizo bridge chip i.e. a total maximum of 16 devices per schizo.</pre>
650<p>---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------</p>
651<h2><a name="SCSI init file Setup|outline"></a><a
652 name="SCSI init file Setup|outline"></a><a
653 name="SCSI init file Setup|outline"></a><a
654 name="SCSI init file Setup|outline"></a><a
655 name="SCSI init file Setup|outline"></a>
656SCSI init file Setup</h2>
657<p><font color="#000000"><font face="Thorndale, serif"><font size="3">Here
658is a sample TPCC and a sample SAP scsi disk init file.</font></font></font></p>
659<pre>################################## start of TPCC scsidisk.init file ##############################<br><br>t13d0s0 ./root.img.fc<br>t13d0s1 ./swap.img<br>t0d0s2 /net/cop4/Simics/install/import/pauly-girl1/pauly.home2.s0 vtoc<br>t0d0s3 /net/cop4/Simics/install/import/pauly-girl1/pauly.home.s3<br><font
660 color="#000000"><font face="Cumberland, monospace"><font size="2">t0d0s4 /net/cop4/Simics/install/import/pauly-girl1/pauly.rootdg.s4</font></font></font>
661
662<font color="#000000"><font face="Cumberland, monospace"><font size="2">################################# end of TPCC scsidisk.init file #################################</font></font></font>
663
664<font color="#000000"><font face="Thorndale, serif"><font size="3">The controller number is assigned automatically. The format is: &lt;logical name without controller number&gt; &lt;path to disk image&gt; [,vtoc]</font></font></font>
665<font color="#000000"><font face="Thorndale, serif"><font size="3">If vtoc is specified then blaze uses the vtoc to read the disk image. If you specify vtoc make sure the slice is always 2 in the logical name.</font></font></font>
666<font color="#000000"><font face="Thorndale, serif"><font size="3">The above example does not work if any of the disks are under Solaris Volume Manager (SVM) control. The example below for SAP</font></font></font>
667<font color="#000000"><font face="Thorndale, serif"><font size="3">takes care of SVM issues.</font></font></font>
668
669<font color="#000000"><font face="Cumberland, monospace"><font size="2">################################# start of SAP scsidisk.init file ################################</font></font></font>
670
671<font face="Cumberland, monospace"><font size="2">t1d0s0 ./root.img</font></font>
672<font face="Cumberland, monospace"><font size="2">t1d0s1 ./swap.img</font></font>
673<font color="#000000"><font face="Cumberland, monospace"><font size="2">t2d0s2 /net/cop4/Simics/mnts/mnt24/sap_2005_new/c2t5d0s0 vtoc serial-no="3BT0667C000010431BQJ" revision-id="5221" </font></font></font>
674<font color="#000000"><font face="Cumberland, monospace"><font size="2">product-id="ST318404LSUN18G" vendor-id="SEAGATE"</font></font></font>
675
676<font color="#000000"><font face="Cumberland, monospace"><font size="2">################################ end of SAP scsidisk.init file ####################################</font></font></font>
677
678<font color="#000000"><font face="Thorndale, serif"><font size="3">As you can see in the above SAP scsidisk.init file example the line for t2d0s2 has lots of extra parameters that are required for SVM to correctly</font></font></font>
679<font color="#000000"><font face="Thorndale, serif"><font size="3">access disks under SVM control. The information needed can be gathered on the referenence machine using prtconf -v | grep c2t5d0s0. In this</font></font></font>
680<font color="#000000"><font face="Thorndale, serif"><font size="3">case c2t5d0s0 is the logical name of the disk on the reference machine.</font></font></font></pre>
681<p>---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------</p>
682<h2><a name="FC init file Setup|outline"></a><a
683 name="FC init file Setup|outline"></a><a
684 name="FC init file Setup|outline"></a><a
685 name="FC init file Setup|outline"></a>
686FC init file Setup</h2>
687<p><font color="#000000"><font face="Thorndale, serif"><font size="3">Here
688is a sample TPCC and a sample fcdisk init file.</font></font></font></p>
689<pre>################################# start of TPCC fcdisk1.multi1.init file ##################################<br><br>/dev/dsk/t0d0s2 /net/cop4/Simics/install/import/10k10g/c11t0d0s2 0 vtoc 21000004cf27c89e 21000004cf27c89e<br>/dev/dsk/t1d0s2 /net/cop4/Simics/install/import/10k10g/c11t10d0s2 0 vtoc 21000004cf27efd7 21000004cf27efd7<br>/dev/dsk/t2d0s2 /net/cop4/Simics/install/import/10k10g/c11t16d0s2 0 vtoc 21000004cf27c8e1 21000004cf27c8e1<br>/dev/dsk/t3d0s2 /net/cop4/Simics/install/import/10k10g/c11t17d0s2 0 vtoc 21000004cf27f29a 21000004cf27f29a<br>/dev/dsk/t4d0s2 /net/cop4/Simics/install/import/10k10g/c11t18d0s2 0 vtoc 21000004cf27c26c 21000004cf27c26c<br>/dev/dsk/t5d0s2 /net/cop4/Simics/install/import/10k10g/c11t19d0s2 0 vtoc 21000004cf27e26c 21000004cf27e26c<br>/dev/dsk/t6d0s2 /net/cop4/Simics/install/import/10k10g/c11t1d0s2 0 vtoc 21000004cf27c16f 21000004cf27c16f<br>/dev/dsk/t7d0s2 /net/cop4/Simics/install/import/10k10g/c11t20d0s2 0 vtoc 21000004cf27c74a 21000004cf27c74a<br>/dev/dsk/t8d0s2 /net/cop4/Simics/install/import/10k10g/c11t21d0s2 0 vtoc 21000004cf27cc06 21000004cf27cc06<br>/dev/dsk/t9d0s2 /net/cop4/Simics/install/import/10k10g/c11t22d0s2 0 vtoc 21000004cf27c64c 21000004cf27c64c<br>/dev/dsk/t10d0s2 /net/cop4/Simics/install/import/10k10g/c11t23d0s2 0 vtoc 21000004cf27c6ee 21000004cf27c6ee<br>/dev/dsk/t11d0s2 /net/cop4/Simics/install/import/10k10g/c11t24d0s2 0 vtoc 21000004cf27c5af 21000004cf27c5af<br>/dev/dsk/t12d0s2 /net/cop4/Simics/install/import/10k10g/c11t25d0s2 0 vtoc 21000004cf27f9dd 21000004cf27f9dd<br>/dev/dsk/t13d0s2 /net/cop4/Simics/install/import/10k10g/c11t26d0s2 0 vtoc 21000004cf27cd8b 21000004cf27cd8b<br><font
690 color="#000000"><font face="Cumberland, monospace"><font size="2">/dev/dsk/t14d0s2 /net/cop4/Simics/install/import/10k10g/c11t2d0s2 0 vtoc 21000004cf27e712 21000004cf27e712</font></font></font>
691
692<font color="#000000"><font face="Cumberland, monospace"><font size="2">################################ end of TPCC fcdisk1.multi1.init file ######################################</font></font></font>
693
694<font color="#000000"><font face="Thorndale, serif"><font size="3">The controller is assigned automatically. The format is &lt;logical name without controller number&gt; &lt;path to disk image&gt; 0 vtoc &lt;portname&gt; &lt;nodename&gt;.</font></font></font>
695<font color="#000000"><font face="Thorndale, serif"><font size="3">&lt;portname&gt; and &lt;nodename&gt; are identical and are obtained by doing a ls -al on the logical name in /dev/dsk directory for each of the data disks. For example:</font></font></font>
696
697lrwxrwxrwx 1 root root 85 Jul 20 11:57 c12t1d0s2 -&gt; ../../devices/ssm@0,<font
698 size="3"><font face="Thorndale, serif"><font color="#000000">0/pci@19,700000/pci@3/</font></font></font>
699<font size="3"><font face="Thorndale, serif"><font color="#000000">SUNW,qlc@4/fp@0,</font></font></font>0/ssd@w50020f2300006207,<font
700 size="3"><font face="Thorndale, serif"><font color="#000000">0:c</font></font></font>
701
702<font color="#000000"><font face="Thorndale, serif"><font size="3">portname = nodename = 50020f2300006207</font></font></font>
703
704<font color="#000000"><font face="Thorndale, serif"><font size="3">The above example works when the data disks are under Veritas control. We need extra data when data disks are under SVM control. Given below is an SAP</font></font></font>
705<font color="#000000"><font face="Thorndale, serif"><font size="3">fc init file as an example.</font></font></font>
706
707<font color="#000000"><font face="Cumberland, monospace"><font size="2">############################################## start of SAP fcdisk.data1.init file ##########################################</font></font></font>
708
709t0d0s2 /net/cop4/Simics/mnts/mnt24/sap_2005_new/c4t2d0s0 0 vtoc 210000203733adb7 200000203733adb7 revision-id="0929" product-id="ST39102FCSUN9.0G" vendor-id="SEAGATE" port-wwn=21.00.00.20.37.33.ad.b7 node-wwn=20.00.00.20.37.33.ad.b7
710
711t1d0s2 /net/cop4/Simics/mnts/mnt24/sap_2005_new/c4t3d0s0 0 vtoc 21000020372b7c40 20000020372b7c40 revision-id="0728" product-id="ST39102FCSUN9.0G" vendor-id="SEAGATE" port-wwn=21.00.00.20.37.2b.7c.40 node-wwn=20.00.00.20.37.2b.7c.40
712
713t2d0s2 /net/cop4/Simics/mnts/mnt24/sap_2005_new/c4t4d0s0 0 vtoc 21000020372b81f6 20000020372b81f6 revision-id="0728" product-id="ST39102FCSUN9.0G" vendor-id="SEAGATE" port-wwn=21.00.00.20.37.2b.81.f6 node-wwn=21.00.00.20.37.2b.81.f6
714
715t3d0s2 /net/cop4/Simics/mnts/mnt24/sap_2005_new/c4t5d0s0 0 vtoc 21000020372b77ad 20000020372b77ad revision-id="0728" product-id="ST39102FCSUN9.0G" vendor-id="SEAGATE" port-wwn=21.00.00.20.37.2b.77.ad node-wwn=20.00.00.20.37.2b.77.ad
716
717t4d0s2 /net/cop4/Simics/mnts/mnt24/sap_2005_new/c4t6d0s0 0 vtoc 21000020372b806e 20000020372b806e revision-id="0728" product-id="ST39102FCSUN9.0G" vendor-id="SEAGATE" port-wwn=21.00.00.20.37.2b.80.6e node-wwn=20.00.00.20.37.2b.80.6e
718
719t5d0s2 /net/cop4/Simics/mnts/mnt24/sap_2005_new/c4t7d0s0 0 vtoc 21000020372b6ee1 20000020372b6ee1 revision-id="0728" product-id="ST39102FCSUN9.0G" vendor-id="SEAGATE" port-wwn=21.00.00.20.37.2b.6e.e1 node-wwn=20.00.00.20.37.2b.6e.e1
720
721t6d0s2 /net/cop4/Simics/mnts/mnt24/sap_2005_new/c4t8d0s0 0 vtoc 21000020372b81cd 20000020372b81cd revision-id="0728" product-id="ST39102FCSUN9.0G" vendor-id="SEAGATE" port-wwn=21.00.00.20.37.2b.81.cd node-wwn=20.00.00.20.37.2b.81.cd
722
723t15d0s2 /net/cop4/Simics/mnts/mnt24/sap_2005_new/c4t9d0s0 0 vtoc 21000020372b8284 20000020372b8284 revision-id="0728" product-id="ST39102FCSUN9.0G" vendor-id="SEAGATE" port-wwn=21.00.00.20.37.2b.82.84 node-wwn=20.00.00.20.37.2b.82.84
724
725t8d0s2 /net/cop4/Simics/mnts/mnt24/sap_2005_new/c6t2d0s0 0 vtoc 2100002037331084 2000002037331084 revision-id="0728" product-id="ST39102FCSUN9.0G" vendor-id="SEAGATE" port-wwn=21.00.00.20.37.33.10.84 node-wwn=20.00.00.20.37.33.10.84
726
727t9d0s2 /net/cop4/Simics/mnts/mnt24/sap_2005_new/c6t3d0s0 0 vtoc 210000203722e506 200000203722e506 revision-id="0728" product-id="ST39102FCSUN9.0G" vendor-id="SEAGATE" port-wwn=21.00.00.20.37.22.e5.06 node-wwn=20.00.00.20.37.22.e5.06
728
729t10d0s2 /net/cop4/Simics/mnts/mnt24/sap_2005_new/c6t4d0s0 0 vtoc 2100002037330d60 2000002037330d60 revision-id="0728" product-id="ST39102FCSUN9.0G" vendor-id="SEAGATE" port-wwn=21.00.00.20.37.33.0d.60 node-wwn=20.00.00.20.37.33.0d.60
730
731t11d0s2 /net/cop4/Simics/mnts/mnt24/sap_2005_new/c6t5d0s0 0 vtoc 2100002037330d78 2000002037330d78 revision-id="0728" product-id="ST39102FCSUN9.0G" vendor-id="SEAGATE" port-wwn=21.00.00.20.37.33.0d.78 node-wwn=20.00.00.20.37.33.0d.78
732
733t12d0s2 /net/cop4/Simics/mnts/mnt24/sap_2005_new/c6t6d0s0 0 vtoc 2100002037330fef 2000002037330fef revision-id="0728" product-id="ST39102FCSUN9.0G" vendor-id="SEAGATE" port-wwn=21.00.00.20.37.33.0f.ef node-wwn=20.00.00.20.37.33.0f.ef
734
735t13d0s2 /net/cop4/Simics/mnts/mnt24/sap_2005_new/c6t7d0s0 0 vtoc 21000020373318c6 20000020373318c6 revision-id="0728" product-id="ST39102FCSUN9.0G" vendor-id="SEAGATE" port-wwn=21.00.00.20.37.33.18.c6 node-wwn=20.00.00.20.37.33.18.c6
736
737<font color="#000000"><font face="Cumberland, monospace"><font size="2">t14d0s2 /net/cop4/Simics/mnts/mnt24/sap_2005_new/c6t8d0s0 0 vtoc 2100002037330fb7 2000002037330fb7 revision-id="0728" product-id="ST39102FCSUN9.0G" vendor-id="SEAGATE" port-wwn=21.00.00.20.37.33.0f.b7 node-wwn=20.00.00.20.37.33.0f.b7</font></font></font>
738
739<font color="#000000"><font face="Cumberland, monospace"><font size="2">############################################ end of SAP fcdisk.data1.init file #############################################</font></font></font>
740
741<font color="#000000"><font face="Thorndale, serif"><font size="3">As you see above for SVM to correctly access data disks under SVM control we need extra parameters. The information needed can be gathered on the referenence </font></font></font>
742<font color="#000000"><font face="Thorndale, serif"><font size="3">machine using prtconf -v | grep c6t8d0s0. In this case c6t8d0s0 is the logical name of the disk on the reference machine which is the last in the above list.</font></font></font></pre>
743<p>---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------</p>
744<h2><a name="Disk Image file from a Reference System|outline"></a><a
745 name="Disk Image file from a Reference System|outline"></a><a
746 name="Disk Image file from a Reference System|outline"></a><a
747 name="Disk Image file from a Reference System|outline"></a><a
748 name="Disk Image file from a Reference System|outline"></a><a
749 name="Disk Image file from a Reference System|outline"></a>
750Disk Image file from a Reference System</h2>
751<p>You have to have root access to that host system -</p>
752<ol>
753 <li>
754 <p>Login as root and run &#8221;prtvtoc&#8221; on the disk where the root
755partition resides to get the disk configuration,</p>
756 </li>
757</ol>
758<p style="margin-left: 0.49in;">You can know where the root partition
759is by looking at /etc/vfstab and see the device logical link that is
760mounted at /. For example if the root partition is c0t1d0s0 do a
761prtvtoc on slice 2 of the disk i.e. c0t1d0s2.</p>
762<ol>
763 <p><font size="2">#prtvtoc /dev/rdsk/c0t1d0s2</font></p>
764</ol>
765<pre> * /dev/rdsk/c0t1d0s2 partition map<br> *<br> * Dimensions:<br> * 512 bytes/sector<br> * 248 sectors/track<br> * 19 tracks/cylinder<br> * 4712 sectors/cylinder<br> * 7508 cylinders<br> * 7506 accessible cylinders<br> *<br> * Flags:<br> * 1: unmountable<br> * 10: read-only<br> *<br> * First Sector Last<br> * Partition Tag Flags Sector Count Sector Mount Directory<br> 0 2 00 0 31273544 31273543 /<br> 1 3 01 31273544 4094728 35368271<br> 2 5 00 0 35368272 35368271</pre>
766<ol start="2">
767 <li>
768 <p>From above vtoc table, the root partition starts from 0 (first
769sector) and total in 31273544 sector counts. Slice 2 of a disk is a
770special slice that points to the entire disk and so when you do dd your
771input is slice 2 of the disk that holds the root partition. Using the
772following command to create a root disk image:</p>
773 </li>
774</ol>
775<ol start="3">
776 <p>dd if=/dev/dsk/c0t1d0s2 of=/blaze/aa/lren/env09-root iseek=0
777count=31273544</p>
778 <p>The general format is the following:</p>
779 <p>dd if=&#8221;partition 2 of the disk with root resides, partition 2
780points to the entire disk&#8221; of=&#8221;disk image file name&#8221; iseek=&#8221;first
781sector&#8221; count=&#8221;sector count&#8221;</p>
782 <li>
783 <p>Follow above steps 1 and 2 for the swap partition as well to
784generate swap disk image file.</p>
785 </li>
786</ol>
787<p>---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------</p>
788<h2><a name="Modifying root image to boot on SAM|outline"></a>Modifying
789root image to boot on SAM</h2>
790<p>Before making following changes to your root disk image, mount the
791disk file as a lofi device, by doing</p>
792<pre> lofiadm -a "your root image file"<br> mount /lofi/dev/x /tmp/root-image </pre>
793<p>where x is the lofi device number from "lofiadm -a" above
794command and /tmp/root-image is where your root image will be mounted.
795Be very careful when modifying root image because you are root on the
796machine on which you have the root image mounted. For example if you
797want to delete /etc/path_to_inst remember that it is
798/tmp/root-image/etc/path_to_inst that needs to be deleted. Before
799doing rm or mv or editing any file always do pwd to make sure you are
800in /tmp/root-image/...</p>
801<p>Please note, </p>
802<ul>
803 <li>
804 <p style="margin-bottom: 0in;">you need to "umount" and "lofiadm
805-d" after you are done with the changes </p>
806 </li>
807 <li>
808 <p>/tmp/root-image will be referenced in this document as the the
809device your root image</p>
810 </li>
811</ul>
812<ol>
813 <li>
814 <p>Install drivers.</p>
815 </li>
816</ol>
817<p style="margin-left: 0.79in;">Copy following drivers from
818/import/blazetrace/blz-binaries/drivers/ to
819/tmp/root-image/kernel/drv/sparcv9,</p>
820<ol>
821 <ol>
822 <pre>pcisimd<br>pcisimc<br>bid</pre>
823 </ol>
824</ol>
825<p style="margin-left: 0.79in;">Solaris 9</p>
826<ol>
827 <ol start="0">
828 <pre style="margin-bottom: 0.2in;">Copy following drivers from /import/blazetrace/blz-binaries/drivers/ to /tmp/root-image/kernel/drv/sparcv9</pre>
829 </ol>
830</ol>
831<pre style="margin-left: 0.98in;">ll<br>Copy following driver from /import/blazetrace/blz-binaries/drivers/ to /tmp/root-image/kernel/fs/sparcv9<br>llfs<br>Create /tmp/root-image/usr/lib/fs/llfs directory and copy /import/blazetrace/blz-binaries/drivers/mount into that directory.</pre>
832<p style="margin-left: 0.79in;">Solaris 10</p>
833<ol>
834 <ol start="0">
835 <pre style="margin-bottom: 0.2in;">Copy following drivers from /import/blazetrace/blz-binaries/drivers/S10_63/ to /tmp/root-image/kernel/drv/sparcv9</pre>
836 </ol>
837</ol>
838<pre style="margin-left: 0.99in;">ll<br>Copy following driver from /import/blazetrace/blz-binaries/drivers/S10_63/ to /tmp/root-image/kernel/fs/sparcv9<br>llfs<br>Create /tmp/root-image/usr/lib/fs/llfs directory and copy /import/blazetrace/blz-binaries/drivers/S10_63/mount into that directory.</pre>
839<ol start="2">
840 <li>
841 <p>Create device nodes</p>
842 </li>
843</ol>
844<pre style="margin-left: 0.48in; margin-bottom: 0.2in;">cd /tmp/root-image/devices</pre>
845<ol start="2">
846 <pre>mkdir pci@1f,600000<br>cd pci@1f,600000</pre>
847</ol>
848<pre style="margin-left: 0.48in; margin-bottom: 0.2in;"><font
849 face="Thorndale, serif"><font size="3">You need to do the following for root and swap only. Let us assume here that root is at /dev/dsk/c0t0d0s0 and swap is at /dev/dsk/c0t0d0s1.</font></font></pre>
850<ol start="2">
851 <pre>mkdir scsi@0<br>mknod scsi@0:devctl c 50 0<br>mknod scsi@0:scsi c 50 1<br>cd scsi@0<br>mknod sd@0,0:a b 32 0<br>mknod sd@0,0:a,raw c 32 0<br>mknod sd@0,0:b b 32 1<br>mknod sd@0,0:b,raw c 32 1</pre>
852</ol>
853<pre style="margin-left: 0.48in;"><font face="Thorndale, serif"><font
854 size="3">scsi@0 is for c0 and it stands for controller 0. sd@0,0 is for t0 and d0 i.e. target 0 and disk 0. The :a stands for s0 or slice 0 and :b stands for s1 or slice 1.</font></font>
855
856<font face="Thorndale, serif"><font size="3">The 50 stands for major device number for scsi controller and this is used by solaris to load the appropriate device driver in this case glm. Look at /etc/name_to_major file and grep for 50. The 32 stands for major device number for scsi disk. You will find sd entry in /etc/name_to_major as well. Look at man pages for further details.</font></font>
857<font face="Thorndale, serif"><font size="3">Minor number calculation:</font></font></pre>
858<ol start="2">
859 <pre style="margin-bottom: 0.2in;">minor number = (controller_id * 120) + (target_id * 8) + (partition_id)</pre>
860</ol>
861<pre style="margin-left: 0.47in;">Examples:<br>c1t0d0s0: minor number = 1*120 + 0*0 + 0 = 120<br>c1t1d0s3: minor number = 1*120 + 1*8 + 3 = 131</pre>
862<ol start="3">
863 <li>
864 <p>Create dev links<br>
865Here is the example to link c0t0d0s0 and c0t0d0s1 to their device
866nodes. If there are existing names, please do mkdir OFF and mv them
867into that directory before performing the following links.</p>
868 </li>
869</ol>
870<pre> cd /tmp/root-image/dev/dsk<br> ln -s ../../devices/pci@1f,600000/scsi@0/sd@0,0:a c0t0d0s0<br> ln -s ../../devices/pci@1f,600000/scsi@0/sd@0,0:b c0t0d0s1<br> cd /tmp/root-image/dev/rdsk<br> ln -s ../../devices/pci@1f,600000/scsi@0/sd@0,0:a,raw c0t0d0s0<br> ln -s ../../devices/pci@1f,600000/scsi@0/sd@0,0:b,raw c0t0d0s1<br><br><font
871 face="Thorndale, serif"><font size="3">Note that although you only create device nodes in step 2 for root and image you have to create these /dev/dsk links or logical names for all disks that you need for simulation for example data disks from a database. We will talk about this later in this document.</font></font></pre>
872<ol start="4">
873 <li>
874 <p>Create llfs file system mount point</p>
875 </li>
876</ol>
877<pre> cd /tmp/root-image/<br> mkdir ll<br> cd ll<br> mkdir root<br><br><font
878 face="Thorndale, serif"><font size="3">This is used to access the local file system which will get mounted under /ll/root on the simulated machine during boot.</font></font></pre>
879<ol start="5">
880 <li>
881 <p>Administrative works in /etc directory</p>
882 </li>
883</ol>
884<p style="margin-left: 0.49in;">Save or remove host system specific
885files.</p>
886<p style="margin-left: 1in;">The list of files here is system
887dependent. Your target system might not have more or less than what
888are mentioned here.</p>
889<pre style="margin-left: 0.99in;">cd /tmp/root-image/etc<br> mkdir OFF<br> mv defaultdomain dumpadm hostname* hosts mnttab path_to_inst OFF<br> cd /tmp/root-image/etc/rcS.d<br> mkdir OFF<br> mv S50devfsadm OFF<br> </pre>
890<p style="margin-left: 0.5in;">Modifications for /etc files</p>
891<pre> /tmp/root-image/etc/system - add following line <br> set pcisch:pci_buserr_interrupt=0<br> <br> /tmp/root-image/etc/vfstab - for example,<br> #device device mount FS fsck mount mount<br> #to mount to fsck point type pass at boot options<br> #<br> fd - /dev/fd fd - no -<br> /proc - /proc proc - no -<br> /dev/dsk/c0t0d0s1 - - swap - no -<br> /dev/dsk/c0t0d0s0 /dev/rdsk/c0t0d0s0 / ufs 1 no -<br> %/ - /ll/root llfs - yes -<br> <br> And any additional disks you would like to map, for example<br> /dev/dsk/c0t2d0s0 - /export/apps ufs 1 no -<br> <br> /tmp/root-image/etc/name_to_major &#8211; find a available major number for Blaze specific devices and add<br> pcisimd 251<br> pcisimc 252<br> bid 253<br> ll 254<br><br>The device numbers assigned here need not be 251, 252 etc. Just go to the end of the file name_to_major<br>and start assigning numbers greater than the highest number you see in the file.<br><br> /tmp/root-image/etc/shadow &#8211; change the login password for root login<br> root::11431::::::<br> <br> /tmp/root-image/etc/minor_perm &#8211; add the following line<br> pcisimc:* 0660 root sys<br><br> /tmp/root-image/etc/iu.ap - add pcisimc here otherwise the text output wont line up on Blaze console.<br> pcisimc 0 0 ldterm ttcompat</pre>
892<ol start="6">
893 <li>
894 <p>Blaze specific files</p>
895 </li>
896</ol>
897<pre> /tmp/root-image/etc/hosts &#8211; you need a unique name and IP address within the subnet where you are going to run Blaze<br> for example,<br> #<br> # Blaze internet hosts file<br> #<br> 127.0.0.1 localhost loghost<br> 129.144.10.170 moan<br><br> /tmp/root-image/etc/path_to_inst &#8211; the path_to_inst for blas&eacute; only need one line as following,<br> #path_to_inst_bootstrap_1<br><br>If you have database disks under SVM in your simulation setup then you need to refer to the following<br>section to modify path_to_inst file:<br><br> /tmp/root-image/etc/mnttab &#8211; make it a empty file for Blaze.</pre>
898<p>---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------</p>
899<h2><a name="Check-pointing using Dump/Restore|outline"></a><a
900 name="Check-pointing using Dump/Restore|outline"></a>
901Check-pointing using Dump/Restore</h2>
902<p>Certain benchmarks takes weeks to run. It is always a good idea to
903generate checkpoints along the way. If multiple SAM simulations are
904connected using switchsim and they are running in time-sync mode do
905the following to generate checkpoint:</p>
906<p><i><b>At switchsim prompt: sync off</b></i></p>
907<p><i><b>At each SAM prompt: stop</b></i></p>
908<p><i><b>At each SAM prompt: dump &lt;checkpointdir&gt;</b></i></p>
909<p>Where &lt;checkpointdir&gt; is the path to where the checkpoint
910will be stored. Make sure you have enough disk space in the partition
911of the &lt;checkpointdir&gt;. Once checkpoint is generated do the
912following to continue running:</p>
913<p><i><b>At each SAM prompt: sync on</b></i></p>
914<p><i><b>At switchsim prompt: sync on</b></i></p>
915<p>It is not advisable to run multiple SAMs without time-sync being
916&#8220;on&#8221; in switchsim.</p>
917<p>If your simulation involves only one SAM then to generate the
918checkpoint do the following:</p>
919<p><i><b>At SAM prompt: stop</b></i></p>
920<p><i><b>At SAM prompt: dump &lt;checkpointdir&gt;</b></i></p>
921<p>To restore SAM from a checkpoint add &#8220;<b><i>-R
922&lt;checkpointdir&gt;</i></b>&#8221; to the SAM run command. Make
923sure your config.rc is the same as what was used during checkpoint
924generation.</p>
925<p>Once your benchmark is warmed and ready to be traced you will
926generate a pretracing checkpoint. This is a very important checkpoint
927which will not only be used to generate traces but also to do
928execution-driven simulation by attaching SAM to a cycle-accurate CPU
929simulator which restores from the same checkpoint.</p>
930<p>---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------</p>
931<h2><a name="Lazy Restore|outline"></a><a name="Lazy Restore|outline"></a>
932Lazy Restore</h2>
933<p>Frequently, you will want to restore from a large checkpoint with
934a huge amount of memory and built-up disk state, but only run for a
935short amount of time. Because of the short simulation duration, you
936will not read every memory page or every disk block. The lazy restore
937feature allows you to restore from a large checkpoint and run the
938simulation with a smaller memory and disk footprint. <br>
939<br>
940For
941example, consider a realistic database simulation with 64GB of
942simulated memory, and 10 TB of disk images with 500 GB of accumulated
943disk updates (overlays). <br>
944<br>
945When this checkpoint is restored,
946SAM does not make a copy of the entire accumulated overlay files.
947Instead, it memory-maps the overlay from the checkpoint, and only
948writes newer updates to the overlay files in the working directory.
949This feature is always enabled on SAM. <br>
950<br>
951A similar optimization
952is available for the simulated memory, where you can restore the
953simulation on a machine with less available memory than simulated.
954This is achieved by specifying the <b><i>-nonemreserve</i></b> option
955to the SAM command-line. <br>
956<br>
957Keep in mind that in both these
958cases, SAM does not reserve memory or disk space on the real machine
959for the corresponding simulated RAM/disk, and if the simulation runs
960long enough, a failure can happen as no more space is available to
961simulate more updates to memory or disk. </p>
962<p>==========================================================================================================================================</p>
963<h1><a name="11.Running SAM Huron|outline"></a>Running SAM Huron</h1>
964<p>To run SAM, launch the SAM binary from the SAM run directory.
965Ofcourse before running SAM Chplus we need a solaris root image,
966configuration files etc. The following sections explain in detail the
967steps that need to be done. Most of the steps in here are the same as
968for SAM Chplus. That is the reason you will links back to SAM Chplus
969documentation in most places. I have provided explanation for steps
970that are unique to SAM Huron in this section. For <a
971 href="#Getting%20Started%7Coutline"><b>Getting
972Started</b></a>, <a href="#Creating%20a%20Root%20Image%7Coutline"><b>Creating
973a Root Image</b></a>, <a href="#Data%20Disk%20Images%7Coutline"><b>Data
974Disk Images</b></a>, <a href="#SCSI%20init%20file%20Setup%7Coutline"><b>SCSI
975init file Setup</b></a>, <a href="#FC%20init%20file%20Setup%7Coutline"><b>FC
976init file Setup</b></a>, <a
977 href="#Disk%20Image%20file%20from%20a%20Reference%20System%7Coutline"><b>Disk
978Image file from a Reference System</b></a>, <a
979 href="#Check-pointing%20using%20Dump/Restore%7Coutline"><b>Check-pointing
980using Dump/Restore</b></a><b> </b>and <a
981 href="#Lazy%20Restore%7Coutline"><b>Lazy
982Restore</b></a> refer to SAM Chplus documentation.</p>
983<p>---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------</p>
984<h2><a name="Getting and running SAM Huron|outline"></a>Getting and
985running SAM Huron</h2>
986<p>Go to the directory where you want the SAM to be installed and run
987the following command. Note that SAM chplus, SAM vonk etc. are all in
988one workspace.</p>
989<p><i><b># bringover -p /import/archperf/ws/sam -w ./&lt;samdir&gt; .</b></i></p>
990<p><i><b># cd &lt;samdir&gt;</b></i></p>
991<p><i><b># make install-n2</b></i></p>
992<p style="font-style: normal;">The above command
993will build the Huron version of SAM. The above command will create a
994directory install-n2. You will find the following directories under
995install-chplus directory: bin, doc, etc, lib, man, pfe, rtl. The bin
996directory has the sam binary and the lib directory has all the
997loadable modules for devices. </p>
998<p style="font-style: normal;">Before you can run
999SAM Huron the run directory must contain the following files:</p>
1000<ol>
1001 <li value="1">
1002 <p><font face="Thorndale, serif"><font size="3"><b>bin/sam:</b> sam
1003binary</font></font></p>
1004 </li>
1005 <li>
1006 <p><font face="Thorndale, serif"><font size="3"><b>lib/*.so:</b>
1007the lib directory contains all the loadable modules (*.so)</font></font></p>
1008 </li>
1009 <li>
1010 <p><font face="Thorndale, serif"><b>config.rc:</b> the rc file
1011where system configuration is specified. </font><a
1012 href="#RC%20file%20Setup%7Coutline">RC file Setup</a></p>
1013 </li>
1014 <li>
1015 <p><font face="Thorndale, serif"><b>scsidisk.init:</b> there could
1016be more than one of these files. </font><a
1017 href="#SCSI%20init%20file%20Setup%7Coutline">SCSI init file Setup</a></p>
1018 </li>
1019 <li>
1020 <p><font face="Thorndale, serif"><b>1c1t-hv.bin:</b> </font> </p>
1021 </li>
1022 <li>
1023 <p><b>1c1t-md.bin:</b> </p>
1024 </li>
1025 <li>
1026 <p><b>q.bin:</b> </p>
1027 </li>
1028 <li>
1029 <p><b>reset.bin:</b> </p>
1030 </li>
1031 <li>
1032 <p><b>openboot.bin:</b> </p>
1033 </li>
1034 <li>
1035 <p><b>nvram.bin:</b> </p>
1036 </li>
1037 <li>
1038 <p><b>root.img:</b> link to or a copy of the modified root image. <a
1039 href="#Disk%20Image%20file%20from%20a%20Reference%20System%7Coutline">Disk
1040Image file from a Reference System</a></p>
1041 </li>
1042 <li>
1043 <p><b>swap.img:</b> link to or a copy of swap image. <a
1044 href="#Disk%20Image%20file%20from%20a%20Reference%20System%7Coutline">Disk
1045Image file from a Reference System</a></p>
1046 </li>
1047</ol>
1048<p><font color="#000000"><font face="Thorndale, serif"><font size="3"><u><b>Without
1049networking:</b></u></font></font></font></p>
1050<p><font color="#000000"><font face="Thorndale, serif"><font size="3"><i><b>#
1051bin/sam -c config.rc</b></i></font></font></font></p>
1052<p><font color="#000000"><font face="Thorndale, serif"><font size="3">The
1053-w is not needed here because it is the default. The -w automatically
1054brings up the console window of the simulated machine. Make sure you
1055have set your DISPLAY environment variable correctly.</font></font></font></p>
1056<p><font color="#000000"><font face="Thorndale, serif"><font size="3">At
1057blaze prompt: run</font></font></font></p>
1058<p><font color="#000000"><font face="Thorndale, serif"><font size="3">In
1059the simulated window do the following:</font></font></font></p>
1060<pre style="margin-left: 0.5in;">After getting the ok prompt select ll device by typing<br>dev /pci@0/pci@0/pci108e,0@2<br><br>Type the following to create needed properties (spaces are important below) <br>" ll" encode-string " name" property<br>2 encode-int " #size-cells" property <br>3 encode-int " #address-cells" property<br><br>At ok prompt type to start booting<br><font
1061 color="#000000"><font face="Thorndale, serif"><font size="3"><font
1062 size="2"><font face="Cumberland, monospace">boot /pci@0/pci@0/scsi@1/disk -vV</font></font> </font></font></font></pre>
1063<p><font color="#000000"><font face="Thorndale, serif"><font size="3"><u><b>With
1064networking:</b></u></font></font></font></p>
1065<p><font color="#000000"><font face="Thorndale, serif"><font size="3">Make
1066sure you have created a file called hostname.ge0 in /etc/system
1067directory on root image and the file should have the machine name in
1068it.</font></font></font></p>
1069<p><font color="#000000"><font face="Thorndale, serif"><font size="3">It
1070could be ge0 or ce0 depending the NIC card gem or cassini being used.
1071It could be ge0 or ge1 depending on the name specified in rc file for
1072the device.</font></font></font></p>
1073<ol>
1074 <li>
1075 <p><font color="#000000"><font face="Thorndale, serif"><font
1076 size="3">Start switchsim on any machine using command: <b><i>#
1077/import/blaze-trace/blz-binaries/switch-v1.6 -r ip</i></b>. Switch does
1078the following:</font></font></font></p>
1079 <ol>
1080 <ol type="a">
1081 <li>
1082 <p><font color="#000000"><font face="Thorndale, serif"><font
1083 size="3">connects multiple blaze simulated environments together</font></font></font></p>
1084 </li>
1085 <li>
1086 <p><font color="#000000"><font face="Thorndale, serif"><font
1087 size="3">models network delay</font></font></font></p>
1088 </li>
1089 <li>
1090 <p><font color="#000000"><font face="Thorndale, serif"><font
1091 size="3">sync multiple blazes on time boundaries</font></font></font></p>
1092 </li>
1093 <li>
1094 <p><font color="#000000"><font face="Thorndale, serif"><font
1095 size="3">behaves as a traditional switch in a real network</font></font></font></p>
1096 </li>
1097 </ol>
1098 </ol>
1099 </li>
1100 <li>
1101 <p><font color="#000000"><font face="Thorndale, serif"><font
1102 size="3">Start blaze and connect to switch</font></font></font></p>
1103 </li>
1104</ol>
1105<pre style="margin-left: 0.5in;"><i><b># bin/sam -c config.rc</b></i>
1106At blaze prompt: &#8220;simge connect &lt;machine name&gt;&#8221; where &lt;machine name&gt; is the machine on which switchsim is running
1107At blaze prompt: &#8220;sync connect &lt;machine name&gt;&#8221; where &lt;machine name&gt; is the machine on which switchsim is running
1108<font color="#000000"><font face="Cumberland, monospace"><font size="2">At blaze prompt: &#8220;conf&#8221; ensure correct values for all parameters, if not, change using &#8220;conf &lt;parameter&gt; &lt;value&gt;&#8221;</font></font></font>
1109<font color="#000000"><font face="Cumberland, monospace"><font size="2">At blaze prompt: run</font></font></font></pre>
1110<p style="margin-left: 0.49in;"><font color="#000000"><font
1111 face="Thorndale, serif"><font size="3">In
1112the simulated window do the following:</font></font></font></p>
1113<pre style="margin-left: 0.5in;">After getting the ok prompt select ll device by typing<br>dev /pci@0/pci@0/pci108e,0@2<br><br>Type the following to create needed properties (spaces are important below) <br>" ll" encode-string " name" property<br>2 encode-int " #size-cells" property <br>3 encode-int " #address-cells" property<br><br>At ok prompt type to start booting<br><font
1114 color="#000000"><font face="Cumberland, monospace"><font size="2">boot /pci@0/pci@0/scsi@1/disk -vV</font></font></font></pre>
1115<ol start="3">
1116 <li>
1117 <pre style="margin-bottom: 0.2in;"><font color="#000000"><font
1118 face="Thorndale, serif"><font size="3">Bringup ge/ce NIC</font></font></font></pre>
1119 </li>
1120</ol>
1121<pre style="margin-left: 0.5in;">After boot login as root in the simulated machine and then run the following commands in the simulated machine:<br>devfsadm -i ge<br>ifconfig ge0 plumb<br>ifconfig ge0 inet &lt;ip address&gt; netmask &lt;net mask&gt;<br>ifconfig ge0 ether &lt;mac address&gt;, mac address is currently not being used in SAM<br>ifconfig ge0 up</pre>
1122<ol start="4">
1123 <li>
1124 <p>Start other blazes and connect them using steps 2 and 3 above.</p>
1125 </li>
1126 <li>
1127 <p>Check to see if the simulated machines are communicating using
1128traditional ping etc.</p>
1129 </li>
1130</ol>
1131<p>---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------</p>
1132<h2><a name="Huron RC file Setup|outline"></a>Huron RC file Setup</h2>
1133<p><font color="#000000"><font face="Thorndale, serif"><font size="3">Here
1134is a sample TPCE rc file. I included TPCE because it covers all the
1135facets of the setup.</font></font></font></p>
1136<pre>############################################### start of rc file ###########################################################<br><br>conf ramsize 65536M<br><br>conf mips 1000<br><br>conf cpu_per_thread 1<br><br>conf stickfreq 1417000000<br><br>load bin 1c2t-hv.bin 0x1f12080000<br>load bin 1c2t-md.bin 0x1f12000000<br><br>load bin ./nvram.bin 0x1f11000000<br><br>sysconf -p ./<br><br>sysconf cpu name=cpu0 cpu-type=SUNW,UltraSPARC-N2 clock-frequency=1417000000 id=0<br>sysconf cpu name=cpu1 cpu-type=SUNW,UltraSPARC-N2 clock-frequency=1417000000 id=1<br><br>sysconf ioram reset start_pa=0xfff0000000 size=0x10000 file=reset.bin sparse<br>sysconf ioram hv start_pa=0xfff0010000 size=0x70000 file=q.bin sparse<br>sysconf ioram obp start_pa=0xfff0080000 size=0x80000 file=openboot.bin sparse<br><br>sysconf serial_4v hypervisor-console base=0xfff0c2c000 size=0x1000<br><br>sysconf serial_4v guest-console base=0x9f10000000 size=0x51 pop log=1c2t.guest.log<br><br>sysconf tod_4v tod base=0xfff0c1fff8 size=0x8 tod=01010000002000 -d2<br><br>sysconf n2_ncu ncu<br>sysconf n2_piu piu bus=pciea ncu=ncu<br>sysconf pcie_bus pciea bridge=piu<br>sysconf bridge b0 bus=pciea dev=0 fun=0 secbus=pcia<br>sysconf bridge b2 bus=pciea dev=0 fun=2 secbus=pcib<br><br>sysconf pci_bus pcia bridge=b0<br>sysconf pci_bus pcib bridge=b2 <br><br>sysconf scsi scsi0 bus=pcia dev=1 fun=0 targets=scsidisk1.init <br>sysconf ll ll0 bus=pcia dev=2 fun=0<br>sysconf gem ge0 bus=pcia dev=3 fun=0 <br><br>sysconf fc fc1 bus=pcib dev=1 fun=0 targets=fcdisk2.1.init<br>sysconf fc fc2 bus=pcib dev=2 fun=0 targets=fcdisk2.2.init<br>sysconf fc fc3 bus=pcib dev=3 fun=0 targets=fcdisk2.3.init<br>sysconf fc fc4 bus=pcib dev=4 fun=0 targets=fcdisk2.4.init<br>sysconf fc fc5 bus=pcib dev=5 fun=0 targets=fcdisk2.5.init<br>sysconf fc fc6 bus=pcib dev=6 fun=0 targets=fcdisk2.6.init<br>sysconf fc fc7 bus=pcib dev=7 fun=0 targets=fcdisk2.7.init<br>sysconf fc fc8 bus=pcib dev=8 fun=0 targets=fcdisk2.8.init<br>sysconf fc fc9 bus=pcib dev=9 fun=0 targets=fcdisk2.9.init<br><br>################################################### end of rc file ###########################################################</pre>
1137<p><br>
1138<br>
1139</p>
1140<p><font face="Thorndale, serif">Here is an explanation of each of
1141the above lines:</font></p>
1142<pre><b>conf ramsize 65536M</b> &#8211; size of RAM or Memory on simulated machine<br><br><font
1143 face="Cumberland, monospace"><b>conf mips 1000</b> &#8211; Useful in cpi </font>calculation. CPI is calculated by the formula: CPU clock frequency in Mhz / mips. For example <br>in the above rc file the CPI will be 1417 <font
1144 face="Cumberland, monospace">/ 1000 = 1.417.</font>
1145
1146<b>conf cpu_per_thread 1</b> &#8211; blaze is a multi-threaded (MP-on_MP) application. In this case the rc file specifies 8 cpus and the <br>cpu_per_thread of 1 means blaze creates 8 threads for 8 cpus i.e. 1 thread to handle each cpu. If the cpu_per_thread value <br>were 2 blaze will create 4 threads to handle 8 cpus i.e. 2 cpus per thread. Apart from the cpu threads blaze creates 1 thread <br>per disk controller (scsi and/or fc). The UI in blaze runs on a separate thread.<br><br><b>conf stickfreq 1417000000</b> &#8211; run the binary /home/vsreeni/bin/stick on the reference machine and the output is the stick frequency.<br>Solaris uses STICK and STICK_COMPARE registers to keep track of time. stickfreq value defines the frequency at which the STICK<br>register update happens. Note that for Huron based systems stickfreq and cpufreq are the same.<br><br><b>load bin 1c2t-hv.bin 0x1f12080000 </b>- guest partition description, currently from Legion workspace<br><br><b>load bin 1c2t-md.bin 0x1f12000000</b> &#8211; machine description, currently from Legion workspace<br><br><b>load bin ./nvram.bin 0x1f11000000</b> - a zero filled file, obtained by modifying an existing nvram file.<br><br><b>sysconf -p ./</b> - indicates the directory in which the loadable modules are present in this case ./ i.e. current directory. In <br>latest blaze I think this is not changeable i.e. the search path for loadable modules is hard-coded to ./lib<br><br><b>sysconf cpu name=cpu0 cpu-type=SUNW,UltraSPARC-N2 clock-frequency=1417000000 id=0</b> &#8211; cpu specification<br><br><b>sysconf ioram reset start_pa=0xfff0000000 size=0x10000 file=reset.bin sparse</b> - reset code, HV workspace<br><br><b>sysconf ioram hv start_pa=0xfff0010000 size=0x70000 file=q.bin sparse</b> - hypervisor, HV workspace<br><br><b>sysconf ioram obp start_pa=0xfff0080000 size=0x80000 file=openboot.bin sparse</b> - OBP, OBP workspace<br><br><b>sysconf serial_4v hypervisor-console base=0xfff0c2c000 size=0x1000</b> - specification for serial console, the hypervisor console <br>of the simulated machine<br><br><b>sysconf serial_4v guest-console base=0x9f10000000 size=0x51 pop log=1c2t.guest.log</b> - specification for serial console, the <br>console of the simulated machine<br><br><b>sysconf tod_4v tod base=0xfff0c1fff8 size=0x8 tod=01010000002000 -d2</b> - specification for time of day device module. -d2<br>specifies the debug level.<br><br><b>sysconf n2_ncu ncu</b> &#8211; non-cacheable unit<br><br><b>sysconf n2_piu piu bus=pciea ncu=ncu</b> &#8211; pcie interface unit<br><br><b>sysconf pcie_bus pciea bridge=piu</b> - pci bus specification and the bridge it is attached<br><br><b>sysconf bridge b0 bus=pciea dev=0 fun=0 secbus=pcia</b> - specification for bridge chip and the names of pci buses attached to <br>the bridge.<br><br><b>sysconf pci_bus pcia bridge=b0</b> - pci bus specification and the bridge it is attached. <br><br><b>sysconf scsi scsi0 bus=pcia dev=1 fun=0 targets=scsidisk1.init</b> - specification for scsi controller, states that scsi controller<br>scsi0 is on bus pcia. All the disks attached to this controller are specified in scsidisk.init. <br><a
1147 href="#5.HOWTO:%20setup%20run%20directory%20scsi%20init%20file%7Coutline">#5.HOWTO: setup run directory scsi init file|outline</a>
1148
1149<b>sysconf ll ll0 bus=pcia dev=2 fun=0</b> - specification for access to local file system, ll module<br><br><b>sysconf gem ge0 bus=pcia dev=3 fun=0</b> - specification for gem device module which is ethernet card<br><br><b>sysconf fc fc1 bus=pcib dev=1 fun=0 targets=fcdisk2.1.init</b> - similar to scsi controller this is a <br>specification fc controller PCCfc01 which is attached to bus pciA30 of schizo30 bridge chip. The fc disks attached to this <br>controller are in fcdisk1.multi1.init. <a
1150 href="#6.HOWTO:%20setup%20run%20directory%20fc%20init%20file%7Coutline">#6.HOWTO: setup run directory fc init file|outline</a>
1151
1152
1153-----------------------------------------------------------------------------------------------------------------------------------------------------------</pre>
1154<h2><a name="Modifying root image to boot on SAM Huron|outline"></a>Modifying
1155root image to boot on SAM Huron</h2>
1156<p>Before making following changes to your root disk image, mount the
1157disk file as a lofi device, by doing</p>
1158<pre> lofiadm -a "your root image file"<br> mount /lofi/dev/x /tmp/root-image </pre>
1159<p>where x is the lofi device number from "lofiadm -a" above
1160command and /tmp/root-image is where your root image will be mounted.
1161Be very careful when modifying root image because you are root on the
1162machine on which you have the root image mounted. For example if you
1163want to delete /etc/path_to_inst remember that it is
1164/tmp/root-image/etc/path_to_inst that needs to be deleted. Before
1165doing rm or mv or editing any file always do pwd to make sure you are
1166in /tmp/root-image/...</p>
1167<p>Please note, </p>
1168<ul>
1169 <li>
1170 <p style="margin-bottom: 0in;">you need to "umount" and "lofiadm
1171-d" after you are done with the changes </p>
1172 </li>
1173 <li>
1174 <p>/tmp/root-image will be referenced in this document as the the
1175device your root image</p>
1176 </li>
1177</ul>
1178<ol>
1179 <li>
1180 <p>Install drivers.</p>
1181 </li>
1182</ol>
1183<p style="margin-left: 0.79in;">Copy following drivers from
1184/import/blazetrace/blz-binaries/drivers/ to
1185/tmp/root-image/kernel/drv/sparcv9,</p>
1186<ol>
1187 <ol>
1188 <pre>pcisimd<br>pcisimc<br>bid</pre>
1189 </ol>
1190</ol>
1191<p style="margin-left: 0.79in;">Solaris 11</p>
1192<ol>
1193 <ol start="0">
1194 <pre style="margin-bottom: 0.2in;">Copy following drivers from /import/blazetrace/blz-binaries/drivers/S11/ to /tmp/root-image/kernel/drv/sparcv9</pre>
1195 </ol>
1196</ol>
1197<pre style="margin-left: 0.99in;">ll<br>Copy following driver from /import/blazetrace/blz-binaries/drivers/S11/ to /tmp/root-image/kernel/fs/sparcv9<br>llfs<br>Create /tmp/root-image/usr/lib/fs/llfs directory and copy /import/blazetrace/blz-binaries/drivers/S11/mount into that directory.</pre>
1198<ol start="2">
1199 <li>
1200 <p>Create llfs file system mount point</p>
1201 </li>
1202</ol>
1203<pre> cd /tmp/root-image/<br> mkdir ll<br> cd ll<br> mkdir root<br><br><font
1204 face="Thorndale, serif"><font size="3">This is used to access the local file system which will get mounted under /ll/root on the simulated machine during boot.</font></font></pre>
1205<ol start="3">
1206 <li>
1207 <p>Administrative works in /etc directory</p>
1208 </li>
1209</ol>
1210<p style="margin-left: 0.49in;">Save or remove host system specific
1211files.</p>
1212<p style="margin-left: 1in;">The list of files here is system
1213dependent. Your target system might not have more or less than what
1214are mentioned here.</p>
1215<pre style="margin-left: 0.99in;">cd /tmp/root-image/etc<br> mkdir OFF<br> mv defaultdomain dumpadm hostname* hosts mnttab path_to_inst OFF<br> cd /tmp/root-image/etc/rcS.d<br> mkdir OFF<br> mv S50devfsadm OFF<br> </pre>
1216<p style="margin-left: 0.5in;">Modifications for /etc files</p>
1217<pre> /tmp/root-image/etc/system - add following line <br> set pcisch:pci_buserr_interrupt=0<br> <br> /tmp/root-image/etc/vfstab - for example,<br> #device device mount FS fsck mount mount<br> #to mount to fsck point type pass at boot options<br> #<br> fd - /dev/fd fd - no -<br> /proc - /proc proc - no -<br> /dev/dsk/c0t0d0s1 - - swap - no -<br> /dev/dsk/c0t0d0s0 /dev/rdsk/c0t0d0s0 / ufs 1 no -<br> %/ - /ll/root llfs - yes -<br> <br> And any additional disks you would like to map, for example<br> /dev/dsk/c0t2d0s0 - /export/apps ufs 1 no -<br> <br> /tmp/root-image/etc/name_to_major &#8211; find a available major number for Blaze specific devices and add<br> pcisimd 251<br> pcisimc 252<br> bid 253<br> ll 254<br><br>The device numbers assigned here need not be 251, 252 etc. Just go to the end of the file name_to_major<br>and start assigning numbers greater than the highest number you see in the file.<br><br> /tmp/root-image/etc/shadow &#8211; change the login password for root login<br> root::11431::::::<br> <br> /tmp/root-image/etc/minor_perm &#8211; add the following line<br> pcisimc:* 0660 root sys<br><br> /tmp/root-image/etc/iu.ap - add pcisimc here otherwise the text output wont line up on Blaze console.<br> pcisimc 0 0 ldterm ttcompat</pre>
1218<ol start="4">
1219 <li>
1220 <p>Blaze specific files</p>
1221 </li>
1222</ol>
1223<pre> /tmp/root-image/etc/hosts &#8211; you need a unique name and IP address within the subnet where you are going to run Blaze<br> for example,<br> #<br> # Blaze internet hosts file<br> #<br> 127.0.0.1 localhost loghost<br> 129.144.10.170 moan<br><br> /tmp/root-image/etc/path_to_inst &#8211; the path_to_inst for blas&eacute; only need one line as following,<br> #path_to_inst_bootstrap_1<br><br>If you have database disks under SVM in your simulation setup then you need to refer to the following<br>section to modify path_to_inst file:<br><br> /tmp/root-image/etc/mnttab &#8211; make it a empty file for Blaze.</pre>
1224<p><br>
1225<br>
1226</p>
1227<p>==========================================================================================================================================</p>
1228<h1><a name="12.Tracing|outline"></a>Tracing</h1>
1229<p>This is one of the primary functions of SAM i.e. to be able to
1230generate traces which contain both user and kernel instructions.
1231Traces are used by cycle accurate simulators to make performance
1232projections. This sections explains how to gather a trace, generate
1233and gather statistics, running various scripts as part of trace
1234validation and reporting of trace.</p>
1235<p>---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------</p>
1236<h2><a name="Trace Collection and Validation|outline"></a>Trace
1237Collection and Validation</h2>
1238<p>The RST tracer module rstracer.so is a shared object located in
1239the SAM directory. You must dynamically link/load it with SAM via.
1240RSTracer registers call back functions such as, instructions, Traps,
1241TLB update and DMAs. RST writes the record to an output trace file.</p>
1242<p>After you restore from pretracing checkpoint do the following at
1243SAM prompt:</p>
1244<p><i><b>sam: stop</b></i></p>
1245<p><i><b>sam: mod load analyzer ./rstracer.so</b></i></p>
1246<p><i><b>sam: run</b></i></p>
1247<p>Always make sure you stop before loading the RSTracer. Ofcourse
1248SAM is in stop state after you restore from pretracing checkpoint but
1249make it a habit to double-check everything.</p>
1250<p>Once we restore from pretracing checkpoint we are ready to start
1251tracing. It is not sufficient to just load the rstracer. We then have
1252to specify certain parameters to the rstracer. You can type &#8220;<b><i>help
1253rstrace</i></b>&#8221; at SAM prompt (once rstracer is loaded) to get
1254help on parameters. </p>
1255<p>You can collect either a single trace or a series of K sample
1256traces each NN instructions long, with each trace separated by PP
1257instructions. </p>
1258<p>The trace will be a compressed RST trace. We apply RST compression
1259and then gzip compression, which typically gives a 30X compression.
1260If you insist on consuming incredible amounts of disk space, you can
1261collect an uncompressed trace. Additionally, it is faster to collect
1262a compressed trace than an uncompressed trace. In SAM v5 by default a
1263value trace is collected.</p>
1264<p>By default, a trace name &#8220;bigeasy&#8221; will be the name of
1265your file. For example, bigeasy-2002-04-15_16-
126616-12-10707-1:0.1.rz2.gz. Clearly, the date and time and the PID of
1267sam is put into the filename. Additionally, there is a tracing
1268request number, the current sample and the total number of samples to
1269the trace name in a format. Each time you specify a (set of samples)
1270trace, the trace request number is bumped.</p>
1271<p><i><b>rstrace -o &lt;file&gt; -n &lt;insts-per-cpu&gt; -d
1272&lt;initial-delay-per-cpu&gt; -x &lt;ntraces&gt; -p
1273&lt;period-per-cpu&gt;</b></i></p>
1274<p>All durations are in terms of per-cpu instruction counts.</p>
1275<p>For further details on tracing and validation of traces refer to:
1276<a
1277 href="http://traces.sfbay/twiki/pub/Traces/Documentation/Tracing_doc041406.pdf">http://traces.sfbay/twiki/pub/Traces/Documentation/Tracing_doc041406.pdf</a></p>
1278<p>The pdf document also contains a sample validation report. You can
1279access a number of validation reports from <a
1280 href="http://traces.sfbay/">http://traces.sfbay</a>.<br>
1281<br>
1282</p>
1283<p>==========================================================================================================================================</p>
1284<h1><a name="14.HOWTOs|outline"></a>HOWTOs</h1>
1285<p>This section has a few howto items and these are not needed for
1286the normal running and tracing in SAM simulation environment. These
1287are more like conveniences.</p>
1288<p>---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------</p>
1289<h2><a name="Open extra Console Windows|outline"></a>Open extra
1290Console Windows</h2>
1291<p>In the default console window that opens up using the -w option do
1292the following:</p>
1293<p><i><b>#export TERM=vt100</b></i></p>
1294<p><i><b>#stty rows 24</b></i></p>
1295<p><i><b>#stty cols 80</b></i></p>
1296<p><i><b>#/ll/root/import/archperf/local/bin/screen</b></i></p>
1297<p>Once it starts, you can use "<b><i>ctrl-a c</i></b>" to
1298create new screens, and "<b><i>ctrl-a n</i></b>" to move to
1299the next one.</p>
1300<p>==========================================================================================================================================</p>
1301<p><br>
1302<br>
1303</p>
1304<p style="margin-bottom: 0in;"><br>
1305</p>
1306<p><br>
1307<br>
1308</p>
1309</body>
1310</html>