Parallel Programming Libraries¶
MPI¶
Message Passing Interface (MPI) is a standardized and portable message-passing parallel programming model to function on distributed memory systems.
The standard defines the syntax and semantics of a core of library routines useful to a wide range of users writing portable message-passing programs in different computer programming languages such as Fortran, C, C++ and Java. There are several well-tested and efficient implementations of MPI.
ARIS supported MPI implementations:
MPI implementations¶
| Hardware interface | MPI flavour | module | version | Execute |
|---|---|---|---|---|
| infiniband/ shared-memory | OpenMPI | openmpi | 4.1.8 | srun |
| infiniband/ shared-memory | MPICH | mpich | 4.3.0 | srun |
| infiniband/ shared-memory | MVAPICH | mvapich | 4.0 | srun |
OpenMPI¶
The Open MPI Project is an open source Message Passing Interface implementation that is developed and maintained by a consortium of academic, research, and industry partners.
For more information visit: OpenMPI website
To load a version of openMPI:
module load openmpi
Currently the 4.1.8 version of openMPI is available compiled with ‘gnu’
| Language | wrapper | module |
|---|---|---|
| C | mpicc | openmpi/4.1.8/gnu |
| C++ | mpicxx | openmpi/4.1.8/gnu |
| FORTRAN | mpif90 | openmpi/4.1.8/gnu |
To use openMPI with gcc/13.3.0 underlying compiler.
module load gnu/13.3.0
module load openmpi/4.1.8/gnu
mpifort -show
gfortran -I/apps/parallel/openmpi/4.1.8/gnu/include -I/apps/parallel/openmpi/4.1.8/gnu/lib
-L/apps/parallel/openmpi/4.1.8/gnu/lib -Wl,-rpath
-Wl,/apps/parallel/openmpi/4.1.8/gnu/lib -Wl,--enable-new-dtags -lmpi_usempif08 -lmpi_usempi_ignore_tkr -lmpi_mpifh -lmpi
MPICH¶
A high-performance and widely portable implementation of the Message-Passing Interface (MPI) standard.
For more information visit: MPICH website
To load a version of MPICH:
module load mpich
Currently, the 4.3.0 version of MPICH is available, compiled with gnu.
module load mpich/4.3.0
mpifort -show
gfortran -I/apps/parallel/mpich/4.3.0/include -I/apps/parallel/mpich/4.3.0/include -L/apps/parallel/mpich/4.3.0/lib -lmpifort -Wl,-rpath -Wl,/apps/parallel/mpich/4.3.0/lib -Wl,--enable-new-dtags -lmpi
mpicc -show
gcc -I/apps/parallel/mpich/4.3.0/include -L/apps/parallel/mpich/4.3.0/lib -Wl,-rpath -Wl,/apps/parallel/mpich/4.3.0/lib -Wl,--enable-new-dtags -lmpi
MVAPICH¶
A high-performance MPI library from The Ohio State University, optimized for clusters with high-speed interconnects.
For more information visit: MVAPICH website
To load a version of MVAPICH:
module load mpich
The available version is MVAPICH 4.0, compiled with the GNU. It provides compiler wrappers for C (mpicc), C++ (mpicxx), and Fortran (mpifort).
module load mpich/4.0
mpifort -show
gfortran -I/apps/parallel/mvapich/4.0/include -I/apps/parallel/mvapich/4.0/include -L/apps/parallel/mvapich/4.0/lib -lmpifort -Wl,-rpath -Wl,/apps/parallel/mvapich/4.0/lib -Wl,--enable-new-dtags -lmpi
mpicc -show
gcc -I/apps/parallel/mvapich/4.0/include -L/apps/parallel/mvapich/4.0/lib -Wl,-rpath -Wl,/apps/parallel/mvapich/4.0/lib -Wl,--enable-new-dtags -lmpi
Launch programs¶
Command srun launches mpi programs.
DON’T USE mpirun AND mpiexec
Global-Arrays-Toolkit¶
Global Arrays is a portable Non-Uniform Memory Access (NUMA) shared-memory programming environment for distributed and shared memory computers. It augments the message-passing model by providing a shared-memory like access to distributed dense arrays. This is also known as the Partitioned Global Address Space (PGAS) model.
For more information visit: Global Arrays website
To load a version of Global Arrays, you first need to load an MPI implementation and then GA itself.
module load openmpi/4.1.8/gnu
module load ga