next up previous
Next: Compiling mpich Up: Users' Guide to mpich, Previous: Documentation

   
Configuring mpich

The next step is to configure mpich for your particular computing environment. mpich can be built for a variety of parallel computers and also for networks of workstations. Parallel computers supported include the IBM SP1 and SP2 (using various communication options), the TMC CM-5, the Intel Paragon, IPSC860, Ncube2, and Touchstone Delta, the Meiko CS-2, the Kendall Square KSR-1 and KSR-2, and SGI and Sun Multiprocessors. Workstations supported are the Sun4 family, Hewlett-Packard, DEC 3000 and Alpha, IBM RS/6000 family, and SGI. Also supported are Intel 386- or 486-based PC clones running the LINUX or FreeBSD operating systems. New ports are always pending.

Configuration of mpich is done with the configure script contained in the top-level directory. This script is automatically generated by the Gnu autoconf program from the file configure.in, but you do not need to have autoconf yourself.

The configure script documents itself in the following way. If you type

    configure -usage
you will get:
Usage: ${progname} -arch=ARCH_TYPE -comm=COMM_TYPE -device=DEVICE
		   [-devicedir=DEVICE_DIR] [-transportdir=TRANSPORT_DIR]
                   [-prefix=INSTALL_DIR]  [-c++=C++_COMPILER]
                   [-mpe] [-nof77] [-opt=OPTFLAGS] [-make=MAKEPGM]
                   [-no_mpegraphics] [-no_short_longs]
                   [-nodevdebug] [-use_rndv] [-pre_post] [-pre_alloc]
		   [-var_pkt] [-pkt_size=LENGTH] [-compressed_pkt]
                   [-limited_buffers] [-adi_collective]
                   [-wish=WISH] [-tcldir=TCLDIR] [-tkdir=TKDIR]
where
   ARCH_TYPE    = the type of machine that MPI is to be configured for
   COMM_TYPE    = communications layer to be used
   DEVICE       = communications device to be used
   INSTALL_DIR  = directory where MPI will be installed (optional)
   DEVICE_DIR   = directory that MPI's ADI code needs (optional)
   TRANSPORT_DIR= directory that MPI's ADI code needs (optional)
   C++_COMPILER = default is to use g++ (optional)
   OPTFLAGS     = optimization flags to give the compilers (e.g. -g)
   MAKEPGM      = version of make to use
   LENGTH       = Length of message at which ADI switches from short
                  to long message protocol
   WISH         = Name of tcl/tk wish executable.  Configure will attempt
                  to find a version of wish for you, but if there is
                  no wish in your path or you need to use a different version,
                  use this option.  Used only for the display tools.
   TCLDIR       = Directory containing tcl.  Must have lib/libtcl.a and
                  include/tcl.h .  Used only for nupshot.
   TKDIR        = Directory containing tk 3.3 or later.  Must have lib/libtk.a
                  and include/tk.h .  Used only for nupshot.  May be
                  the same as TCLDIR.

One and only one 'arch', 'comm', and 'prefix' argument should be
provided.  'arch' MUST be specified before 'comm'.

If '-c++' is included as an option, then the C++ interface is also
built.  By default, g++ is used as the c++ compiler.  THIS IS CURRENTLY
UNSUPPORTED.

If '-mpe' is included as an option, then the MPE 'helper' libraries will
also be built.  If '-no_mpegraphics' is used, then the MPE routines that
make use of X11 graphics will NOT be built; this is appropriate for
systems that either do not have the X11 include files or that do not
support X11 graphics (some message-passing systems can not interoperate
with X11).

The option '-mpedbg' enables the '-mpedbg' command line switch in MPI
programs.  When used with an MPI program, the default error handler
(i.e., MPI_COMM_WORLD's error handler) tries to start xterm's running
dbx for each process that detects an error.  This option is intended
primarily for workstation environments but should work on some MPPs
(such as IBM SP2).

The option '-nof77' prevents the compilation of routines that require a
Fortran compiler.  If this option is selected, you may not use the
Fortran interface to MPI.

The option '-opt' allows you to specify options for the compilers (both
C and Fortran).  For example, '-opt=-O' chooses optimized code
generation on many systems.

The option '-make' may be used to select an alternate make program.  For
example, on FreeBSD systems, -make=gnumake may be required because of
bugs in the system make.

The option '-no_short_longs' may be used to suppress support for ANSI C
types 'long long int' and 'long double' when they are the same size as
'long' and 'double' respectively.  Some systems allow these long ANSI C
types, but generate a warning message when they are used; this option
may be used to suppress these messages (and support for these types).
 
Special Tuning Options:

There are a number of options for tuning the behavior of the ADI
(Abstract Device Interface) which is the low-level message-passing
interface.  These should NOT be used unless you are sure you know what
you are doing.

The option '-nodevdebug' disables the debugging code in the MPI ADI
code.  This should be used only when you are sure that everything is
working correctly.  (This option is also present to remind benchmarkers
that the low level code by default may contain debugging code.)  Note
also that some of the device code (in mpid/*) has had the debugging code
removed from the source code.

The option '-use_rndv' directs MPICH to use a rendevous protocol rather
than an eager protocol in sending messages.  This option is provided
mostly for debugging purposes; a good default is provided for each
system (not yet implemented)

The option '-pre_post' directs MPICH to 'pre-post' a receive for
incoming messages.  This can improve performance for some applications
and make performance worse for others.  It is expected that the effect
will often be small.  Not yet tested.

The option '-pre_alloc' directs MPICH to 'pre-allocate' a message buffer
into which incoming control data can be received.  With the p4 transport
(with either -device=ch_p4 or -device=chameleon and -comm=p4), this may
help reduce memory copy overhead.  -pre_alloc and -pre_post are mutually
exclusive.  Not yet tested.

The option '-var_pkt' allows you to set the message size at which MPICH
changes from its short to long message protocol.

The option '-compressed_pkt' allows you to choose a 'compressed' packet
format; this slightly reduces the size of the message 'envelope', and,
on systems with relatively slow communications, provide slightly better
performance.  Not yet tested.

The option '-pkt_size=LENGTH' allows you to choose the message length at
which the ADI (Abstract Device Interface) switches from its short to
long message format.

The option '-limited_buffers' forces the ADI to be more conservative in
its use of the underlying message-passing system's buffer space.  Some
applications on some systems may need this; however, it can degrade
performance.

The option '-adi_collective' allows the ADI to provide some collective
operations in addition to the basic point-to-point operations.
Currently, most systems do not support this option (it is ignored) and
on the others it has not been extensively tested.


Sample Configure Usage:

To make for running on sun4's running SunOS with ch_p4 as the device,
 and with the installation directory equal to the current directory:

  ./configure -device=ch_p4 -arch=sun4
  make

Known devices are chameleon, 
        ch_nx     (native Intel NX calls), 
        ch_eui    (native IBM EUI or MPL calls),
        ch_mpl    (synonym for ch_eui)
        ch_nc     (native nCUBE calls, requires -arch=ncube),
        ch_cmmd   (native TMC CM-5 CMMD calls), and
        ch_p4     (p4)
        ch_meiko  (For Meiko CS2, using NX compatibility library,
                   the intent is to make this use Elan eventually)

Known architectures include
        sun4      (SUN OS 4.x)
        solaris   (Solaris; probably 2.3 (untested))
        hpux      (HP UX)
        rs6000    (AIX for IBM RS6000)
        sgi       (Silicon Graphics IRIX 5.x or 6.x)
        IRIX      (synonym for sgi)
        alpha     (DEC alpha)
        intelnx   (Intel i860 or Intel Delta)
        paragon   (Intel Paragon)
        meiko     (Meiko CS2)
        CRAY      (CRAY XMP, YMP, C90)
        cray_t3d  (CRAY T3D (untested))
        freebsd   (PC clones running FreeBSD)
        ksr       (Kendall Square KSR1 and KSR2)

Special notes:
For -arch=IRIX -device=ch_p4, setting -comm=shared will enable the shared
memory implementation of the p4 code in the low-level device.

Others may be recognized.

mpich is implemented using an abstract device specification (ADI), described in [3]. In some environments, this abstract device is configured to be the native communication subsystem of the machine. This is done with the device argument to configure. For the rest of the environments, a generic communication device is constructed using p4 and that is used as the instantiation of the ADI. In these cases, use ch_p4 as the device.

The ARCH_TYPE specifies what kind of processor the compilations will take place on. Valid ones are listed above. For the IBM SP1 and SP2, the architecture type is rs6000.

Some machines have multiple communication options, which are specified with the comm argument.

Some sample invocations of configure are:

For the IBM SP2 using the high-performance switch for communication:

    configure -device=ch_eui -arch=rs6000
For the Intel Paragon:
    configure -device=ch_nx -arch=paragon
For the Meiko CS-2:
    configure -device=ch_meiko -arch=meiko
For an SGI workstation:
    configure -device=ch_p4 -arch=sgi
For an SGI multiprocessor, such as an Onyx, Challenge, or Power Challenge, using the shared memory for fast message-passing:
    configure -device=ch_p4 -arch=sgi -comm=shared
For a network of Suns, including the mpe libraries (See Section [*]):
    configure -device=ch_p4 -arch=sun4 -mpe
For a network of DEC alphas:
    configure -device=ch_p4 -arch=alpha
For a network of PC's running the FreeBSD version of Unix:
    configure -device=ch_p4 -arch=freebsd
For a network of HP's, including the mpe library but leaving out of it the MPE X graphics routines:
    configure -device=ch_p4 -arch=hpux -mpe -no_mpegraphics
mpich can be run on a heterogeneous network of workstations of various kinds. In order to do this, however, one must currently use a p4 ``procgroup file''. The format of these files is described in Section [*].


next up previous
Next: Compiling mpich Up: Users' Guide to mpich, Previous: Documentation
Karen D. Toonen
1998-11-19