Building The Instruction-Accurate Simulator (IAS)


IAS has been extensively tested only on the Sparc/Solaris platform. It is compiled with the Sun Workshop C compiler. If you do not have access to this compiler, you can try compiling with gcc.

If you need to build IAS on a different platform, you should read the IAS Porting Notes.

For more on the build structure and details on the source code, please refer to IAS web pages.

Building IAS

A default SPARC/Solaris binary for the Instruction-accurate simulator (IAS) is supplied with the distribution in $DSVHOME/bin.

The steps to recompile IAS for your SPARCstation running Solaris are:

  1. Ensure your environment variables are set. See setting up your environment.
  2. Change your directory to $DSVHOME
  3. Type make ias. The ias executable appears in the directory $DSVHOME/bin if everything builds correctly. (If you see warnings of the form: " warning: typedef redeclared: uint64_t", you can ignore them)

Installing trap handlers

Before you can run a program on IAS or on the RTL model, you must have all picoJava-II trap handlers present in the directory $DSVHOME/class. The picoJava-II processor distributions already contain default trap handlers in this directory. Note that these trap handlers are example implementations only, and may have to be substantially modified before being used in a real system.

If you need to modify or recompile these handlers, the source code is present in $PICOJAVAHOME/$PROJECT/design/traps (for emulation traps) and $PICOJAVAHOME/$PROJECT/design/exception (for all other traps).

The steps to build the trap handlers are:

  1. cd $PICOJAVAHOME/$PROJECT/tools/traps
  2. make
  3. cp class/*.class $DSVHOME/class
  4. cd $PICOJAVAHOME/$PROJECT/tools/exception
  5. make
  6. cp class/*.class $DSVHOME/class

Running tests on IAS

A quick way to check if you built IAS correctly is to run some sample tests. The steps to run the sample tests in IAS are:

  1. Change directory to $PICOJAVAHOME/$PROJECT/sim/test/sample_tests. This directory has 5 precompiled sample tests.

  2. Select one of the tests, e.g., FADD_000 and change to that directory.

  3. Type "ias".

  4. Type "run" at ias prompt "% ".

  5. The output should be something like:
    "IAS: Test PASSED, 3721 instructions, 0 interrupts taken, 0 total traps".
To run all the tests in the picoJava verification test suite on ias, you you need to
build the tests first.
You can then run all the tests on ias with the following commands:
  1. cd $PICOJAVAHOME/$PROJECT/sim/test/pico_vts
  2. Type steam -ias .

Copyright © 1999 Sun Microsystems, Inc. 901 San Antonio Road, Palo Alto, CA 94303-4900 USA. All rights reserved.

Last modified 24-March-1999