SAF
saf_externals.h File Reference

Include header for SAF externals. More...

#include "mkl.h"
#include <netcdf.h>

Go to the source code of this file.

Macros

#define SAF_CURRENT_PERFORMANCE_LIBRARY_STRING   "Intel MKL (LP64)"
 
#define SAF_INTEL_IPP_STATUS_STRING   "Disabled"
 
#define SAF_FFTW_STATUS_STRING   "Disabled"
 
#define SAF_SIMD_STATUS_STRING   "Disabled"
 
#define SAF_ENABLED_SIMD_INTRINSICS_STRING   "None"
 
#define SAF_NETCDF_STATUS_STRING   "Enabled"
 
#define SAF_EXTERNALS_CONFIGURATION_STRING
 Current configuration information. More...
 

Detailed Description

Include header for SAF externals.

Note
Including this header is optional and only needed if you wish to have access to these external libraries in your own project.
Warning
Using ATLAS (SAF_USE_ATLAS) as the performance library is not recommended, since some LAPACK routines are not implemented by the library! However, if you don't mind losing some SAF functionality (namely: certain veclib utility functions), then it may still be a good choice for your particular project.

Required Dependencies

A performance library comprising CBLAS and LAPACK routines is required by SAF. Add one of the following FLAGS to your project's preprocessor definitions in order to enable one of these suitable performance libraries, (which must be correctly linked when building SAF):

  • SAF_USE_INTEL_MKL_LP64: to enable Intel's Math Kernel Library with the Fortran LAPACK interface
  • SAF_USE_INTEL_MKL_ILP64 same as SAF_USE_INTEL_MKL except using int64 and LAPACKE interface
  • SAF_USE_OPENBLAS_WITH_LAPACKE: to enable OpenBLAS with the LAPACKE interface
  • SAF_USE_APPLE_ACCELERATE: to enable the Accelerate framework with the Fortran LAPACK interface
  • SAF_USE_ATLAS: to enable ATLAS BLAS routines and ATLAS's CLAPACK interface

Optional dependencies

netcdf is required by the optional saf_sofa_reader module, which is enabled with the following pre-processor flag: SAF_ENABLE_SOFA_READER_MODULE

Intel IPP may be optionally used with the flag: SAF_USE_INTEL_IPP

FFTW may be optionally used with the flag: SAF_USE_FFTW

SIMD intrinsics support may be enabled with: SAF_ENABLE_SIMD

  • SSE/SSE2/SSE3 intrinsics are used by default
  • AVX/AVX2 intrinsics are enabled with compiler flag: -mavx2
  • AVX-512 intrinsics are enabled with compiler flag: -mavx512f (Note that intrinsics require a CPU that supports them)
See also
More information can be found in the docs folder regarding dependencies
Author
Leo McCormack
Date
06.08.2020
License
ISC

Definition in file saf_externals.h.

Macro Definition Documentation

◆ SAF_EXTERNALS_CONFIGURATION_STRING

#define SAF_EXTERNALS_CONFIGURATION_STRING
Value:
"Current SAF externals configuration: " "\n" \
" - Performance library: " SAF_CURRENT_PERFORMANCE_LIBRARY_STRING "\n" \
" - Intel IPP status: " SAF_INTEL_IPP_STATUS_STRING "\n" \
" - FFTW status: " SAF_FFTW_STATUS_STRING "\n" \
" - SIMD status: " SAF_SIMD_STATUS_STRING "\n" \
" - Enabled intrinsics: " SAF_ENABLED_SIMD_INTRINSICS_STRING "\n" \
" - netCDF status: " SAF_NETCDF_STATUS_STRING "\n"

Current configuration information.

Definition at line 332 of file saf_externals.h.