Ada : Compilation of an MPI parallel code in Fortran, C/C++

The compilating and linking steps of an MPI program are carried out by using the scripts mpiifort for a Fortran code, mpiicc for a C code, and mpiicpc for a C++ code:

$ mpiifort source.f90

$ mpiicc source.c
$ mpiicpc source.C

The compilation commands mpiifort, mpiicc and mpiicpc refer respectively to the INTEL ifort, icc, and icpc compilers. They automatically include the paths for the Fortran MPI module mpif.h and the the paths for the libraries necessary to MPI.

Remarks :

  • The -static option cannot be used explicitly or implicitly (for example, when using -fast) with the INTEL compilation commands mpiifort, mpiicc, mpiicpc because, for network performance reasons, the MPI IBM library is dynamically linked to the MPI code at runtime via the poe command.
  • The execution of an MPI program can be done in interactive or in batch.