1. Introduction Configuring Renoir TM to Drive Simulation On Remote Machines As a major feature and enhancement of Renoir2000, designers now can run ModelSim compilation and simulation on local machine, or on a remote UNIX or Linux server. From the new ModelSim compilation (Figure 1.1) and simulation (Figure 1.2) setting up dialog boxes, designers can choose the remote server from the list, edit remote server list file, and choose one of the three remote simulation modes: interactive, command line or batch mode. Figure 1.1 New ModelSim Compile Settings Dialog Figure 1.2 New ModelSim Invoke Settings Dialog Figure 1.3 illustrate a typical environment of running remote simulation. For example, Renoir is running on a laptop while ModelSim is running on a UNIX box, both of them share a common database which is on a file server. Shared Database Figure 1.3 Working Environment 11/08/00 ZZ/Revision1.0 Mentor Graphics, 1996-2000 Page 1 of 6
2. Pre-Requisites Some running environments are required before you set up and run remote compilation or simulation: 2. 1 Hardware A Windows (Windows95/98/2000/NT) or UNIX machine locally runs Renoir (as LOCAL), UNIX/Linux machines remotely runs ModelSim (as REMOTE) LOCAL and REMOTE are connected via TCP/IP. Use ping command to make sure that the network works. Optionally, use hosts files on both LOCAL and REMOTE to map IP addresses and hostnames so they can communicate with each other using hostnames For Windows95/98, this file is in the directory of c:\windows For WindowsNT, this file is in the directory of %WINNT%\system32\drivers\etc For Windows2000, this file is in the directory of %WINNT%\system32\drivers\etc For UNIX/Linux, this file is in the directory of /etc A file sharing mechanism is needed to make two machines share a same file location. For example, you can configure REMOTE as a file server (like Samba or others) that can export a directory (as DESIGN_DIR) readwritable for LOCAL, and configure LOCAL (if runs Windows) to map DESIGN_DIR as a network driver (as DESIGN_PATH), or configure LOCAL (if runs UNIX/Linux) to mount DESIGN_DIR to a local directory (as DESIGN_PATH) If LOCAL runs Windows, an X server (Exceed or Xvision, etc.) is required to run on LOCAL so ModelSim can show its graphical interface when running remotely (not needed if running in command line or batch mode) An rsh command on LOCAL UNIX/Linux has this command built in (/usr/bin/rsh) WindowsNT/2000 has this command built in (%windir%\system32) For Windows95/98, a freeware version can be found from http://home.us.net/~silviu/ Same account name and password on both LOCAL and REMOTE Renoir must be installed on REMOTE if running interactive mode (no license needed on REMOTE) 2. 2 Environment Variables Required environment variables are: LOCAL: RENOIRHOME => installation path of Renoir on LOCAL LM_LICENSE_FILE => Renoir license file DESIGN => the directory which hold the design data, this directory must be in DESIGN_PATH (the variable name could be any word you want) RENOIR_PORT => <LOCAL hostname>:<port number> => the port number is an unused IPC port number or TCP service name allocated by your system administrator Example 2.1 is an example for Windows95/98, these variables are set in file autoexec.bat: 11/08/00 ZZ/Revision1.0 Mentor Graphics, 1996-2000 Page 2 of 6
set RENOIRHOME=c:\renoir2000 set LM_LICENSE_FILE=c:\flexlm\license.dat set DESIGN=d:\ set RENOIR_PORT=mynt:3170 Example 2.1 Environment Variables for Windows95/98 In this example, drive d: is the network drive which maps the shared directory for both LOCAL and REMOTE; mynt is the hostname of LOCAL, 3170 is an unused port number. REMOTE DESIGN => same as LOCAL, point to the design data in DESIGN_DIR LM_LICENSE_FILE => ModelSim license file For example(example 2.2), in the C shell environment, include followings in your $HOME/.cshrc file: setenv DESIGN=$HOME/MyDesign setenv LM_LICENSE_FILE $HOME/license.dat Example 2.2 Environment Variables for C shell $HOME/MyDesign is the directory mounted from the shared directory for both LOCAL and REMOTE. Note: the value of variable DESIGN on LOCAL may be different from that on REMOTE, they both point to the sharing design data directory using their own physical path names 3. Configuring Renoir The following options should be set up in Renoir: Remote Simulation Directory Location (from the menu Options>Main): This defines the directory where the server list file (see section Server List File for definition) is. Select a location outside the design data or Renoir installation tree so that the file can be kept from being deleted when you re-install the software or remove the design data. (Figure 3.1) Figure 3.1 Remote Simulation Directory Location (From Options>Main) 11/08/00 ZZ/Revision1.0 Mentor Graphics, 1996-2000 Page 3 of 6
Design Library Name (from the menu Options>Library Mappings) For the design data which are planed to be used with remote compilation and simulation, define Renoir library mappings with logical path name instead of physical path name, e.g. (use environment variable $DESIGN). Here is an example(example 3.1): Library Name: SOURCE: HDL: Downstream (for ModelSim): Example 3.1 MyDesign $DESIGN/mydesign/src $DESIGN/mydesign/hdl $DESIGN/mydesign/work Library Mapping Temp Directory (from the menu Options>Compile) This directory should be accessible by both LOCAL and REMOTE, so we define it on a shared file location of REMOTE, for example, $DESIGN/temp. (Figure 3.2) Use logical name ($DESIGN) instead of physical path name since physical path names are different on LOCAL and REMOTE. Figure 3.2 Temp Directory Definition (From Options>Compile) ModelSim Executable Directory Path (choose the menu Options>Compile, select ModelSim, and click Settings) Fill in the physical installation path of ModelSim on REMOTE Figure 3.3 ModelSim Executable Directory Path (From Options>Compile>Compiler Setting) 11/08/00 ZZ/Revision1.0 Mentor Graphics, 1996-2000 Page 4 of 6
Server List File Server List File is a configuration file for defining remote servers. The file should contain one or more SERVER lines which define the remote servers and a COMMAND line which sets up a connection to the currently selected server. SERVER lines A SERVER line can contain any number of space or tab separated arguments but must include the hostname or IP address of the remote machine. Additional arguments can also be specified and optionally be used to help define the COMMAND line. Each argument has a number ($n) associated with it. The first argument ($1) is used to identify the remote servers in the ModelSim Invoke Settings dialog. For example(example 3.2), the following server lines define remote servers for Solaris (hostname server1), HP-UX (hostname server2) and Linux (hostname sever3): SERVER MySolarisServer server1 sunos5 SERVER MyHPServer server2 hp700 SERVER MyLinuxServer server3 linux Example 3.2 Server Lines in Server List File COMMAND line The COMMAND line should typically contain the following components COMMAND rsh $2 or COMMAND remsh $2 Use rsh or remsh to open a shell on the remote server. For HP-UX local host, remsh should be used. In this example, the 2nd argument (server1 or server2 or server3) in the SERVER line is substituted for the $2 argument. cd $CWD; Changes directory to the expanded soft pathname of the current directory If LOCAL is a UNIX machine, this command should be preceded by a single quote and there should be a closing single quote after the final argument setenv RENOIR_PORT $RENOIR_PORT; Sets up the IPC port used for communication between Renoir and the remote setenv DISPLAY LOCAL:0.0; Sets the local host display name used to display graphical interface of the remote simulator. setenv RENOIRHOME <Renoir_Tree_On_REMOTE>; Specifies the location of the Renoir tree on the remote host. setenv PATH $$PATH\:<ModelSim_Excutable_Directory_Path> Adds the ModelSim installation pathname on REMOTE to the default login PATH, please note the double $ sign. setenv LM_LICENSE_FILE <License_Server_Path>; set the license file location for ModelSim on REMOTE, not required if the environment variable exists. setenv MODELSIM_TCL <the path of file ModelSim.tc_ on REMOTE>; Sets the location of the Tcl interface code used by the ModelSim on REMOTE. 11/08/00 ZZ/Revision1.0 Mentor Graphics, 1996-2000 Page 5 of 6
$RUN_CMD Invoke remote simulator. Here is a complete example (Example 3.3) of server list file: win_remote_servers.txt: COMMAND c:\winnt\system32\rsh $2 cd $CWD; setenv RENOIR_PORT $RENOIR_PORT; setenv DISPLAY mynt:0.0; setenv RENOIRHOME /opt/renoir; setenv PATH $$PATH\:/opt/modeltech/$3; setenv LM_LICENSE_FILE 1717@lic_server; setenv MODELSIM_TCL /opt/renoir/resources/misc/modelsim.tc_; $RUN_CMD SERVER MySolarisServer server1 sunos5 SERVER MyHPServer server2 hp700 SERVER MyLinuxServer server3 linux Example 3.3 A Complete Server List File Note: All fields of COMMAND must be in one single line. For remote simulation on Linux, only command line and batch modes are supported. 4. Invoke Remote Simulator from Renoir All the steps for running ModelSim on a remote machine are the same as on a local machine, in addition, you can choose simulation mode from ModelSim invoking setting dialog box as Figure1.2 shown. 11/08/00 ZZ/Revision1.0 Mentor Graphics, 1996-2000 Page 6 of 6