Loading...
Searching...
No Matches
Go to the documentation of this file.
66#ifndef __SAF_EXTERNALS_H_INCLUDED__
67#define __SAF_EXTERNALS_H_INCLUDED__
78#if (defined(SAF_USE_INTEL_MKL_LP64) + \
79 defined(SAF_USE_INTEL_MKL_ILP64) + \
80 defined(SAF_USE_OPEN_BLAS_AND_LAPACKE) + \
81 defined(SAF_USE_ATLAS) + \
82 defined(SAF_USE_GSL) + \
83 defined(SAF_USE_APPLE_ACCELERATE)) != 1
84# error One (and only one) performance library flag should be defined!
94#if defined(SAF_USE_INTEL_MKL_LP64)
110#elif defined(SAF_USE_INTEL_MKL_ILP64)
125#elif defined(SAF_USE_OPEN_BLAS_AND_LAPACKE)
147#elif defined(SAF_USE_ATLAS)
157# include "cblas-atlas.h"
159# warning Note: CLAPACK does not include all LAPACK routines!
161#elif defined(__APPLE__) && defined(SAF_USE_APPLE_ACCELERATE)
180# include "Accelerate/Accelerate.h"
182#elif defined(SAF_USE_GSL)
190# error Using GNU Scientific Library (GSL) is currently unsupported/incomplete
191# include "gsl_cblas.h"
198# error SAF requires a library (or libraries) which supports CBLAS and LAPACK
206#if defined(SAF_USE_INTEL_IPP)
223#if defined(SAF_USE_FFTW)
240#if defined(SAF_ENABLE_SIMD)
259# if (defined(__AVX__) && defined(__AVX2__)) || defined(__AVX512F__)
264# include <immintrin.h>
266# if defined(__SSE__) && defined(__SSE2__) && defined(__SSE3__)
267# include <xmmintrin.h>
268# include <emmintrin.h>
269# include <pmmintrin.h>
271# error SAF_ENABLE_SIMD requires at least SSE, SSE2 and SSE3 support
275#if defined(SAF_ENABLE_SOFA_READER_MODULE)
297# ifdef SAF_ENABLE_NETCDF
308#if defined(SAF_USE_INTEL_MKL_LP64)
309# define SAF_CURRENT_PERFORMANCE_LIBRARY_STRING "Intel MKL (LP64)"
310#elif defined(SAF_USE_INTEL_MKL_ILP64)
311# define SAF_CURRENT_PERFORMANCE_LIBRARY_STRING "Intel MKL (ILP64)"
312#elif defined(SAF_USE_OPEN_BLAS_AND_LAPACKE)
313# define SAF_CURRENT_PERFORMANCE_LIBRARY_STRING "OpenBLAS with LAPACKE"
314#elif defined(SAF_USE_ATLAS)
315# define SAF_CURRENT_PERFORMANCE_LIBRARY_STRING "ATLAS"
316#elif defined(__APPLE__) && defined(SAF_USE_APPLE_ACCELERATE)
317# define SAF_CURRENT_PERFORMANCE_LIBRARY_STRING "Apple Accelerate"
319# define SAF_CURRENT_PERFORMANCE_LIBRARY_STRING "NONE"
323#if defined(SAF_USE_INTEL_IPP)
324# define SAF_INTEL_IPP_STATUS_STRING "Enabled"
326# define SAF_INTEL_IPP_STATUS_STRING "Disabled"
330#if defined(SAF_USE_FFTW)
331# define SAF_FFTW_STATUS_STRING "Enabled"
333# define SAF_FFTW_STATUS_STRING "Disabled"
337#if defined(SAF_ENABLE_SIMD)
338# define SAF_SIMD_STATUS_STRING "Enabled"
340# if defined(__AVX512F__)
341# define SAF_ENABLED_SIMD_INTRINSICS_STRING "SSE, SSE2, SSE3, AVX, AVX2, AVX512F"
342# elif defined(__AVX__) && defined(__AVX2__)
343# define SAF_ENABLED_SIMD_INTRINSICS_STRING "SSE, SSE2, SSE3, AVX, AVX2"
344# elif defined(__SSE__) && defined(__SSE2__) && defined(__SSE3__)
345# define SAF_ENABLED_SIMD_INTRINSICS_STRING "SSE, SSE2, SSE3"
347# define SAF_ENABLED_SIMD_INTRINSICS_STRING "None"
350# define SAF_SIMD_STATUS_STRING "Disabled"
351# define SAF_ENABLED_SIMD_INTRINSICS_STRING "None"
355#if defined(SAF_ENABLE_NETCDF)
356# define SAF_NETCDF_STATUS_STRING "Enabled"
358# define SAF_NETCDF_STATUS_STRING "Disabled"
362#define SAF_EXTERNALS_CONFIGURATION_STRING \
363 "Current SAF externals configuration: " "\n" \
364 " - Performance library: " SAF_CURRENT_PERFORMANCE_LIBRARY_STRING "\n" \
365 " - Intel IPP status: " SAF_INTEL_IPP_STATUS_STRING "\n" \
366 " - FFTW status: " SAF_FFTW_STATUS_STRING "\n" \
367 " - SIMD status: " SAF_SIMD_STATUS_STRING "\n" \
368 " - Enabled intrinsics: " SAF_ENABLED_SIMD_INTRINSICS_STRING "\n" \
369 " - netCDF status: " SAF_NETCDF_STATUS_STRING "\n"