Merge pull request #2658 from RajalakshmiSR/p10
powerpc: Add support for future processor
This commit is contained in:
@@ -6,6 +6,9 @@ extern gotoblas_t gotoblas_POWER8;
|
||||
#if (!defined __GNUC__) || ( __GNUC__ >= 6)
|
||||
extern gotoblas_t gotoblas_POWER9;
|
||||
#endif
|
||||
#if (!defined __GNUC__) || ( __GNUC__ >= 11)
|
||||
extern gotoblas_t gotoblas_POWER10;
|
||||
#endif
|
||||
|
||||
extern void openblas_warning(int verbose, const char *msg);
|
||||
|
||||
@@ -13,7 +16,8 @@ static char *corename[] = {
|
||||
"unknown",
|
||||
"POWER6",
|
||||
"POWER8",
|
||||
"POWER9"
|
||||
"POWER9",
|
||||
"POWER10"
|
||||
};
|
||||
|
||||
#define NUM_CORETYPES 4
|
||||
@@ -23,6 +27,9 @@ char *gotoblas_corename(void) {
|
||||
if (gotoblas == &gotoblas_POWER8) return corename[2];
|
||||
#if (!defined __GNUC__) || ( __GNUC__ >= 6)
|
||||
if (gotoblas == &gotoblas_POWER9) return corename[3];
|
||||
#endif
|
||||
#if (!defined __GNUC__) || ( __GNUC__ >= 11)
|
||||
if (gotoblas == &gotoblas_POWER10) return corename[4];
|
||||
#endif
|
||||
return corename[0];
|
||||
}
|
||||
@@ -36,6 +43,10 @@ static gotoblas_t *get_coretype(void) {
|
||||
#if (!defined __GNUC__) || ( __GNUC__ >= 6)
|
||||
if (__builtin_cpu_is("power9"))
|
||||
return &gotoblas_POWER9;
|
||||
#endif
|
||||
#if (!defined __GNUC__) || ( __GNUC__ >= 11)
|
||||
if (__builtin_cpu_is("isa_3_1") && __builtin_cpu_supports ("mma"))
|
||||
return &gotoblas_POWER10;
|
||||
#endif
|
||||
return NULL;
|
||||
}
|
||||
@@ -61,6 +72,9 @@ static gotoblas_t *force_coretype(char * coretype) {
|
||||
case 2: return (&gotoblas_POWER8);
|
||||
#if (!defined __GNUC__) || ( __GNUC__ >= 6)
|
||||
case 3: return (&gotoblas_POWER9);
|
||||
#endif
|
||||
#if (!defined __GNUC__) || ( __GNUC__ >= 11)
|
||||
case 4: return (&gotoblas_POWER10);
|
||||
#endif
|
||||
default: return NULL;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user