12.07.2015 Views

PGI User's Guide

PGI User's Guide

PGI User's Guide

SHOW MORE
SHOW LESS
  • No tags were found...

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

MPI Overview74MPI is a set of function calls and libraries that are used to send messages between multiple processes. Theseprocesses can be located on the same system or on a collection of distributed servers. Unlike OpenMP, thedistributed nature of MPI allows it to work in almost any parallel environment.Compiling and Linking MPI ApplicationsThe <strong>PGI</strong> compilers provide an option, -Mmpi=, to make building MPI applications more convenient by addingthe MPI include and library directories to the compiler's include and library search paths. The compilerdetermines the location of these directories using various mechanisms described in the MPI implementationspecificsections later in this chapter.Table 6.1 lists the -Mmpi= suboptions for each of the supported implementations.This MPIimplementation...NoteMPICH-1MPICH-2MVAPICHHP-MPIMSMPIOpenMPITable 6.1. MPI Implementation OptionsRequires this option...-Mmpi=mpich1-Mmpi=mpich2-Mmpi=mvapich1-Mmpi=hpmpi-Mmpi=msmpi-Mmpi not supported. Use compiler wrappers.When you use these options to build an MPI application, you must use them in both the compile andlink steps.Debugging MPI ApplicationsThe <strong>PGI</strong> debugger, PGDBG, provides support for symbolic debugging of MPI applications. In <strong>PGI</strong> Workstation,this support is limited in two ways:• The application processes must run on a system where <strong>PGI</strong> Workstation is installed.• The number of processes is limited, controlled by the license key.For all implementations of MPI except MPICH-1, you use the PGDBG command to initiate an MPI debuggingsession. For example, you might invoke an HP-MPI session as follows:% pgdbg -mpi:/opt/hpmpi/bin/mpirun -np 4 my_mpi_appFor specific information on how to initiate a debugging session for your instance of MPI, refer to theimplementation-specific sections available later in this chapter.PGDBG can display the contents of message queues for instances of MPI that have been configured to supportthat feature. The version of MPICH-1 provided with <strong>PGI</strong> Workstation as well as HP-MPI function properly. If

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!