Browse Source

Merge pull request #4298 from ChipKerchner/fixBuiltinsDynamicArch

Only define __builtin_cpu_is and __builtin_cpu_supports if not present.
tags/v0.3.25^2
Martin Kroeker GitHub 2 years ago
parent
commit
0a609cc689
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 0 deletions
  1. +4
    -0
      driver/others/dynamic_power.c

+ 4
- 0
driver/others/dynamic_power.c View File

@@ -202,6 +202,7 @@ static int cpuid(void)
#ifndef __BUILTIN_CPU_SUPPORTS__ #ifndef __BUILTIN_CPU_SUPPORTS__
#include <string.h> #include <string.h>


#if defined(_AIX) || (defined(__has_builtin) && !__has_builtin(__builtin_cpu_is))
static int __builtin_cpu_is(const char *arg) static int __builtin_cpu_is(const char *arg)
{ {
static int ipinfo = -1; static int ipinfo = -1;
@@ -224,12 +225,15 @@ static int __builtin_cpu_is(const char *arg)
} }
return 0; return 0;
} }
#endif


#if defined(_AIX) || (defined(__has_builtin) && !__has_builtin(__builtin_cpu_supports))
static int __builtin_cpu_supports(const char *arg) static int __builtin_cpu_supports(const char *arg)
{ {
return 0; return 0;
} }
#endif #endif
#endif


static gotoblas_t *get_coretype(void) { static gotoblas_t *get_coretype(void) {




Loading…
Cancel
Save