Browse Source

Detect other Intel Skylake cores.

http://users.atw.hu/instlatx64/
tags/v0.2.15^2
Zhang Xianyi 10 years ago
parent
commit
cc7cab8a45
2 changed files with 32 additions and 1 deletions
  1. +22
    -0
      cpuid_x86.c
  2. +10
    -1
      driver/others/dynamic.c

+ 22
- 0
cpuid_x86.c View File

@@ -1133,6 +1133,16 @@ int get_cpuname(void){
return CPUTYPE_HASWELL;
#else
return CPUTYPE_SANDYBRIDGE;
#endif
else
return CPUTYPE_NEHALEM;
case 14:
//Skylake
if(support_avx())
#ifndef NO_AVX2
return CPUTYPE_HASWELL;
#else
return CPUTYPE_SANDYBRIDGE;
#endif
else
return CPUTYPE_NEHALEM;
@@ -1150,6 +1160,7 @@ int get_cpuname(void){
#endif
else
return CPUTYPE_NEHALEM;
case 5:
case 14:
// Skylake
if(support_avx())
@@ -1618,6 +1629,16 @@ int get_coretype(void){
return CORE_HASWELL;
#else
return CORE_SANDYBRIDGE;
#endif
else
return CORE_NEHALEM;
case 14:
//Skylake
if(support_avx())
#ifndef NO_AVX2
return CORE_HASWELL;
#else
return CORE_SANDYBRIDGE;
#endif
else
return CORE_NEHALEM;
@@ -1635,6 +1656,7 @@ int get_coretype(void){
#endif
else
return CORE_NEHALEM;
case 5:
case 14:
// Skylake
if(support_avx())


+ 10
- 1
driver/others/dynamic.c View File

@@ -252,6 +252,15 @@ static gotoblas_t *get_coretype(void){
return &gotoblas_NEHALEM; //OS doesn't support AVX. Use old kernels.
}
}
//Intel Skylake
if (model == 14) {
if(support_avx())
return &gotoblas_HASWELL;
else{
openblas_warning(FALLBACK_VERBOSE, NEHALEM_FALLBACK);
return &gotoblas_NEHALEM; //OS doesn't support AVX. Use old kernels.
}
}
return NULL;
case 5:
//Intel Broadwell
@@ -264,7 +273,7 @@ static gotoblas_t *get_coretype(void){
}
}
//Intel Skylake
if (model == 14) {
if (model == 14 || model == 5) {
if(support_avx())
return &gotoblas_HASWELL;
else{


Loading…
Cancel
Save