Navigation

Spack

AMD Toolchain with SPACK

Micro Benchmarks/Synthetic

SPACK HPC Applications

Introduction

The AMD Optimized CPU Libraries (AOCL) suite consists of a set of numerical libraries tuned specifically for AMD processors.  Each library offers a simple interface to take advantage of the latest processor hardware features.  The tuned implementations of industry-standard math libraries enable rapid development of scientific and high-performance computing projects.

These AOCL libraries are supported with Spack packages:

  • amdblis
  • amdlibflame
  • amdfftw
  • amdscalapack
  • amdlibm
  • aocl-sparse

Please use any combination of below components/Applications and its versions:

Component/Application Versions Applicable
AOCL 3.1, 3.0, 2.2
AOCC 3.2.0, 3.1.0, 3.0.0,  2.3.0, 2.2.0

AMD BLIS

BLIS is a portable, open-source software framework for instantiating high-performance Basic Linear Algebra Subprograms (BLAS), such as dense linear algebra libraries. The framework was designed to isolate essential kernels of computation that, when optimized, immediately enable optimized implementations of most of the commonly used and computationally-intensive operations. Select kernels have been optimized for the AMD EPYC™, AMD Ryzen™, and AMD Ryzen™ Threadripper™ processors and others.

List of variants for use with AMD BLIS:

Variant (Default) Allowed Values Description
ilp64 (off) on, off Build with ILP64 Support
blas (on) on, off BLAS Compatibility
cblas (on) on, off CBLAS Compatibility
shared (on) on, off Build shared library
static (on) on, off Build static library
threads (none) pthreads, openmp, none Multithreading support
Basic commands for amdblis
# Format For Building AMD BLIS with AOCC compiler
$ spack -d install -v amdblis@<Version> %aocc@<Version>
# Example: For Building AMD BLIS-3.1 with AOCC-3.2
$ spack -d install -v amdblis@3.1 %aocc@3.2.0
# Example: For Building AMD BLIS-3.1 with AOCC-3.1
$ spack -d install -v amdblis@3.1 %aocc@3.1.0
# Example: For Building AMD BLIS-3.1 with AOCC-3.2 with ILP64 Support
$ spack -d install -v amdblis@3.1 +ilp64 %aocc@3.2.0
# Example: For Building AMD BLIS-3.1 with AOCC-3.2 with openmp threads
$ spack -d install -v amdblis@3.1 %aocc@3.2.0 threads=openmp

AMD LibFLAME

LibFLAME is a portable library for dense matrix computations, providing much of the functionality present in Linear Algebra Package (LAPACK). LibFLAME includes a Fortran interface compatibility layer, FLAPACK, that includes complete LAPACK implementation. The library provides scientific and numerical-computing communities with a modern, high-performance, dense linear algebra library that is extensible, easy to use, and available under an open source license. In combination with the BLIS library, libFLAME enables running high-performing LAPACK functions with optimization for AMD EPYC™, AMD Ryzen™, and AMD Ryzen™ Threadripper™ processors.

List of variants for use with AMD LibFLAME:

Variant (Default) Allowed Values Description
ilp64 (off) on, off Build with ILP64 support
debug (off) on, off Build with debugging support
lapack2flame (on) on, off Map legacy LAPACK routine invocations to their corresponding native C implementations in libflame
shared (on) on, off >Build shared library
static (on) on, off Build static library
Basic commands for amdlibflame
# Format For Building AMD LibFLAME with AOCC
$ spack -d install -v amdlibflame@<Version> %aocc@<Version>
# Example: For Building AMD LibFLAME-3.1 with AOCC-3.2
$ spack -d install -v amdlibflame@3.1 %aocc@3.2.0
# Example: For Building AMD LibFLAME-3.1 with AOCC-3.1
$ spack -d install -v amdlibflame@3.1 %aocc@3.1.0
# Example: For Building AMD LibFlame-3.1 with AOCC-3.2 with ILP64 Support
$ spack -d install -v amdlibflame@3.1 +ilp64 %aocc@3.2.0

AMD FFTW

FFTW is a comprehensive collection of fast C routines for computing the Discrete Fourier Transform (DFT) and various special cases thereof.  FFTW is an open-source implementation of the Fast Fourier transform algorithm that can compute transforms of real and complex-values arrays of arbitrary size and dimension.  An AMD-optimized FFTW that includes selective kernels and routines optimized for the AMD EPYC™, Ryzen™, and Ryzen™ Threadripper™ processor families is available.

List of variants for use with AMD FFTW:

Variant (Default) Allowed Values Description
amd-top-n-planner (off) on, off Build with amd-top-n-planner support
amd-mpi-vader-limit (off) on, off Build with amd-mpi-vader-limit support
static (off) on, off Build with static support
amd-trans (off) on, off Build with amd-trans support
amd-app-opt (off) on, off Build with amd-opt support
amd-fast-planner (off) on, off Option to reduce the planning time without much tradeoff in the performance. It is supported for float and double precision
debug (off) on, off Builds a debug version of the library
mpi (on) on, off Activate MPI support
openmp (on) on, off Enable OpenMP Support
precision (float,double) long_double, quad, float, double Build the selected floating-point precision libraries
shared (on) on, off Builds a shared version of the library
threads (off) on, off Enable SMP threads support
Basic commands for amdfftw
# Format For Building AMD FFTW with AOCC
$ spack -d install -v amdfftw@<Version> %aocc@<Version>
# Example: For Building AMD FFTW 3.1 with AOCC 3.2.0
$ spack -d install -v amdfftw@3.1 %aocc@3.2.0
# Example: For Building AMD FFTW 3.0 with AOCC-3.1
$ spack -d install -v amdfftw@3.0 %aocc@3.1.0
# Example: For Building AMD FFTW 3.1 for precisions float and double with AOCC 3.2.0 with amd-fast-planner-option
$ spack -d install -v amdfftw@3.1 +amd-fast-planner %aocc@3.2.0 precision=float,double
# Example: For Building AMD FFTW 3.1 for precisions float and double with AOCC 3.2.0 with amd-top-n-planner-option
$ spack -d install -v amdfftw@3.1 +amd-top-n-planner %aocc@3.2.0 precision=float,double

AMD ScaLAPACK

ScaLAPACK is a library of high-performance linear algebra routines for parallel distributed memory machines. ScaLAPACK depends on external libraries, including BLAS and LAPACK, for Linear Algebra computations. AMD’s optimized version of ScaLAPACK enables using the optimized BLIS and libFLAME libraries.

List of variants for use with AMD ScaLAPACK:

Variant (Default) Allowed Values Description
ilp64 (off) on, off Build with ILP64 support
build_type (Release) Release, RelWithDebInfo CMake build type
ipo (off) on. off CMake interprocedural optimization
pic (off) on, off Build position independent code
shared (on) on, off Build the shared library version
Basic Commands for amdscalapack
# Format For Building AMD ScaLAPACK with AOCC
$ spack -d install -v amdscalapack@<Version> %aocc@<Version>
# For Building AMD ScaLAPACK 3.1 with AOCC 3.2.0
$ spack -d install -v amdscalapack@3.1 %aocc@3.2.0
# Example: For Building AMD ScaLAPACK 3.1 with AOCC 3.1.0
$ spack -d install -v amdscalapack@3.1 %aocc@3.1.0
# Example: For Building AMD ScaLAPACK 3.1 with AOCC 3.2.0 with ILP64 support
$ spack -d install -v amdscalapack@3.1 +ilp64 %aocc@3.2.0
# Example: For Building AMD ScaLAPACK 3.1 with AMD LibFLAME 3.1 and AMD BLIS 3.1 and with AOCC 3.2.0
$ spack -d install -v amdscalapack@3.1 %aocc@3.2.0 ^amdlibflame@3.1 ^amdblis@3.1

AMD LibM (Math Library)

AMD LibM is a C software library containing a collection of basic math functions optimized for x86-64 processor based machines. AMD LibM provides many routines from the list of standard C99 math functions that may provide higher accuracy or performance than those offered by the default compiler.

List of variants for use with AMD LibM:

Variant (Default) Allowed Values Description
verbose (off) on, off Building with verbosity
Basic Commands for amdlibm
# Format For Building AMD LIBM with AOCC
$ spack -d install -v amdlibm@<Version> %aocc@<Version>
# Example: For Building AMD LIBM 3.1 with AOCC 3.2.0
$ spack -d install -v amdlibm@3.1 %aocc@3.2.0
# Example: For Building AMD LIBM 3.1 with AOCC 3.1.0
$ spack -d install -v amdlibm@3.1 %aocc@3.1.0
# Example: For Building AMD LIBM 3.1 with AOCC 3.2.0 with verbose
$ spack -d install -v amdlibm@3.1 +verbose %aocc@3.2.0

AOCL-Sparse

AOCL-Sparse is a library of basic linear algebra subroutines for the sparse matrices and vectors optimized for AMD EPYC™, Ryzen™, and Ryzen™ Threadripper™ processor families, designed to be used with C and C++ applications.
AOCL-Sparse functions are organized in two categories:

  1. Sparse Level 2 functions describe the operations between a matrix in sparse format and a vector in dense format.
  2. Sparse Format Conversion functions describe operations on a matrix in sparse format to obtain a different matrix format.

List of variants for use with AOCL-Sparse:

Variant (Default) Allowed Values Description
build_type (Release) Debug, Release CMake build type
ilp64 (off) on, off Build with ILP64 support
ipo (off) on, off CMake interprocedural optimization
shared (on) on, off Build shared library
Basic Commands for aocl-sparse
# Format For Building AOCL Sparse
$ spack -d install -v aocl-sparse@<Version> %aocc@<Version>
# Example: For Building AOCL Sparse 3.1 with AOCC 3.2.0
$ spack -d install-v aocl-sparse@3.1 %aocc@3.2.0
# Example: For Building AOCL Sparse 3.1 with AOCC 3.1.0
$ spack -d install-v aocl-sparse@3.1 %aocc@3.1.0
# Example: For Building AOCL Sparse 3.0 with AOCC-3.0 with ILP64 support
$ spack -d install-v aocl-sparse@3.1 %aocc@3.2.0 +ilp64