Skip to content
Snippets Groups Projects
Commit 4db6d3d8 authored by Martin Reinecke's avatar Martin Reinecke
Browse files

better diagnostics

parent 7ef585e3
No related branches found
No related tags found
1 merge request!17Multiarch
...@@ -18,6 +18,11 @@ static t_architecture architecture_ = NULL; ...@@ -18,6 +18,11 @@ static t_architecture architecture_ = NULL;
#ifdef MULTIARCH #ifdef MULTIARCH
#if (defined(___AVX512F__) || defined(__FMA4__) || defined(__FMA__) || \
defined(__AVX2__) || defined(__AVX__))
#error MULTIARCH specified but platform-specific flags detected
#endif
#define DECL(arch) \ #define DECL(arch) \
static int XCONCATX2(have,arch)(void) \ static int XCONCATX2(have,arch)(void) \
{ \ { \
...@@ -37,21 +42,11 @@ int XCONCATX2(sharp_veclen,arch) (void); \ ...@@ -37,21 +42,11 @@ int XCONCATX2(sharp_veclen,arch) (void); \
int XCONCATX2(sharp_max_nvec,arch) (int spin); \ int XCONCATX2(sharp_max_nvec,arch) (int spin); \
const char *XCONCATX2(sharp_architecture,arch) (void); const char *XCONCATX2(sharp_architecture,arch) (void);
#if (!defined(__AVX512F__))
DECL(avx512f) DECL(avx512f)
#endif
#if (!defined(__FMA4__))
DECL(fma4) DECL(fma4)
#endif
#if (!defined(__FMA__))
DECL(fma) DECL(fma)
#endif
#if (!defined(__AVX2__))
DECL(avx2) DECL(avx2)
#endif
#if (!defined(__AVX__))
DECL(avx) DECL(avx)
#endif
#endif #endif
...@@ -67,21 +62,11 @@ static void assign_funcs(void) ...@@ -67,21 +62,11 @@ static void assign_funcs(void)
architecture_ = XCONCATX2(sharp_architecture,arch); \ architecture_ = XCONCATX2(sharp_architecture,arch); \
return; \ return; \
} }
#if (!defined(__AVX512F__))
DECL2(avx512f) DECL2(avx512f)
#endif
#if (!defined(__FMA4__))
DECL2(fma4) DECL2(fma4)
#endif
#if (!defined(__FMA__))
DECL2(fma) DECL2(fma)
#endif
#if (!defined(__AVX2__))
DECL2(avx2) DECL2(avx2)
#endif
#if (!defined(__AVX__))
DECL2(avx) DECL2(avx)
#endif
#endif #endif
inner_loop_ = inner_loop_default; inner_loop_ = inner_loop_default;
veclen_ = sharp_veclen_default; veclen_ = sharp_veclen_default;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment