Skip to main content

Compilation

If you want to use a software that is not available on MCMeSU, if you develop your own software or if you need a specific version or configuration of a software, you may want to compile it yourself.

You can check the list of software available on MCMeSU to find if we already know your application or its dependencies. In this case, do not hesitate to contact us to get recommendations on optimal configuration parameters.

Compiling with GCC​

To compile your application, we advise you to use the GNU C/C++/Fortran Compilers provided by the system.

They provide great performance and broad compatibility with various C/C++/Fortran standards.

The compilation options we advise are :

  • -march=znver3 for code generation,
  • -O3 for the optimization level.

If you need to bind your code with scientific libraries such as BLAS, LAPACK, FFTW3, etc., we advise you to load AMD Optimized Libraries :

module load amd-aocl/5.1.0/gcc

If not detected by the configure script of your application, use the following information to adapt your configure command-line or Makefile :

  • BLAS LIBRARY : -L${AOCL_ROOT}/lib -lblis
  • LAPACK LIBRARY : -L${AOCL_ROOT}/lib -lflame
  • SCALAPACK LIBRARY : -L${AOCL_ROOT}/lib -lscalapack
  • FFTW3 LIBRARY : -L${AOCL_ROOT}/lib -lfftw3

If your application implements parallelization with MPI, we advise you to load one of the OpenMPI version compiled with GCC, for example :

module load mpi/openmpi/4.1.8/gcc

Compiling with AMD AOCC​

You may also use AMD AOCC compiler if you want, but it does not always offer better performance than GCC.

If you need to bind your code with scientific libraries isuch as BLAS, LAPACK, FFTW3, etc., we advise you to load AMD Optimized Libraries :

module load amd-aocl/4.2.0/aocc

If not detected by the configure script of your application, use the information provided above to adapt your configure command-line or Makefile.

If your application implements parallelization with MPI, we advise you to load one of the OpenMPI version compiled with AMD AOCC, for example :

module load mpi/openmpi/4.1.6/aocc-4.2.0

Compiling with Intel HPC Toolkit​

MCMeSU is based on AMD CPUs, thus, although we provide Intel HPC Toolkit by means of several modules, we advise you to only use it in a case of last resort (strong compatibility issues, etc.).

The most recent installation of Intel HPC Toolkit on MCMeSU can be loaded with the following commands :

module load intel-compilers
module load intel-mkl
module load mpi/intelmpi