ScaLAPACK

From ACENET
Jump to: navigation, search
Description
ScaLAPACK is a library of high-performance linear algebra routines for parallel distributed memory machines. ScaLAPACK solves dense and banded linear systems, least squares problems, eigenvalue problems, and singular value problems.
Modulefile
scalapack
Documentation
ScaLAPACK homepage
IMPORTANT
The BLACS library is now part of ScaLAPACK, you do not need to link the former explicitly.

Usage

Here are examples how one could link their code against ScaLAPACK using different compilers.

GCC
$ module load gcc openmpi/gcc atlas scalapack/gcc

Note that the ATLAS library provides BLAS and LAPACK for GCC. If you link ATLAS dynamically against your code (see below), then please do not forget to load the atlas modulefile every time before you run the binary, as well as a proper openmpi modulefile.

Dynamic linking:

$ mpif90 <compiler commands> -L$SCALAPACK/lib -lscalapack -L$ATLAS/lib -llapack -lf77blas -lcblas -latlas

Static linking:

$ mpif90 <compiler commands> -L$SCALAPACK/lib -lscalapack $ATLAS/lib/liblapack.a $ATLAS/lib/libf77blas.a $ATLAS/lib/libcblas.a $ATLAS/lib/libatlas.a
PGI

Please use vendor-optimized BLAS library ACML.

$ module load pgi openmpi/pgi scalapack/pgi
$ mpif90 <compiler commands> -L$SCALAPACK/lib -lscalapack -lacml
Intel

Please use vendor-optimized BLAS library MKL.

$ module load intel openmpi/intel scalapack/intel
$ mpif90 <compiler commands> -L$SCALAPACK/lib -lscalapack -mkl=sequential -limf