From 186368ddc3775540c147b6300693ccc0bcac7597 Mon Sep 17 00:00:00 2001 From: Martin Kroeker Date: Tue, 16 Mar 2021 16:52:57 +0100 Subject: [PATCH] Fix compilation with CLANG --- driver/others/dynamic_power.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/driver/others/dynamic_power.c b/driver/others/dynamic_power.c index b8e5840a3..d9c15b312 100644 --- a/driver/others/dynamic_power.c +++ b/driver/others/dynamic_power.c @@ -40,7 +40,14 @@ char *gotoblas_corename(void) { return corename[0]; } -#ifdef C_PGI +#if defined(__clang__) +static int __builtin_cpu_supports(char* arg) +{ + return 0; +} +#endif + +#if defined(C_PGI) || defined(__clang__) /* * NV HPC compilers do not yet implement __builtin_cpu_is(). * Fake a version here for use in the CPU detection code below.