acml Overview


The AMD Core Math Library (ACML) is a set of numerical routines tuned specifically for AMD64 platform processors (including OpteronTM and AthlonTM64 ). The routines, which are available via both FORTRAN 77 and C interfaces, include:
  • BLAS - Basic Linear Algebra Subprograms (including Sparse Level 1 BLAS);
  • LAPACK - A comprehensive package of higher level linear algebra routines;
  • FFT - a set of Fast Fourier Transform routines for real and complex data;
  • RNG - a set of random number generators and statistical distribution functions.
The BLAS and LAPACK routines provide a portable and standard set of interfaces for common numerical linear algebra operations that allow code containing calls to these routines to be readily ported across platforms. Full documentation for the BLAS and LAPACK are available online. The FFT is an implementation of the Discrete Fourier Transform (DFT) that makes use of symmetries in the definition to reduce the number of operations required from O(n*n) to O(n*log n) when the sequence length, n, is the product of small prime factors; in particular, when n is a power of 2. Despite the popularity and widespread use of FFT algorithms, the definition of the DFT is not sufficiently precise to prescribe either the forward and backward directions (these are sometimes interchanged), or the scaling factor associated with the forward and backward transforms (the combined forward and backward transforms may only reproduce the original sequence by following a prescribed scaling). Currently, there is no agreed standard API for FFT routines. Hardware vendors usually provide a set of high performance FFTs optimized for their systems: no two vendors employ the same interfaces for their FFT routines. The ACML provides a set of FFT routines, optimized for AMD64 processors, using an ACML-specific set of interfaces. The RNG is a comprehensive set of statistical distribution functions which are founded on various underlying uniform distribution generators (base generators) including Wichmann- Hill and an implementation of the Mersenne Twister. In addition there are hooks which allow you to supply your own preferred base generator if it is not already included in ACML. A supplementary library of fast math and fast vector math functions (ACML MV) is also provided with some 64-bit versions of ACML. Some of the functions included in ACML MV are not callable from high-level languages, but must be called via assembly language. For more information, see ACML User guide and ACML documentation page.



The acml module must be loaded first.
module avail acml
module load acml
Note that the module will set the environment variables based on what compiler you have loaded as a module. If you have multiple compiler modules loaded before loading acml, the environment variables will point to one of the loaded compilers, not more. ACML_DIR points to the installation directory. In this directory, builds for various compilers can be found. On Rhea, it is up to the user to construct the appropriate link line for the compiler in use. For instance the examples seen below could use linker lines similar to
ACML_LIB="-L$ACML_DIR/gfortran64/lib -lacml"
ACML_MPLIB="-L$ACML_DIR/gfortran64_mp/lib -lacml"
Fortran: serial use
pgf90/pathf90/gfortran test.f90 ${ACML_LIB}
multi-core/threaded use:
pgf90/pathf90/gfortran -mp test.f90 ${ACML_MPLIB}
You will probably need to use "-fPIC" or "static" options to make the linking step work. C: serial use
pgcc/pathcc/gcc test.f90 ${ACML_LIB} -lpgf90libs/pathfortran/gfortran
multi-core/threaded use:
pgcc/pathcc/gcc -mp test.f90 ${ACML_MPLIB} -lpgf90libs/pathfortran/gfortran


  • 5.3.1