diff options
Diffstat (limited to 'sysdeps/x86')
-rw-r--r-- | sysdeps/x86/cpu-features.c | 2 | ||||
-rw-r--r-- | sysdeps/x86/cpu-features.h | 4 |
2 files changed, 6 insertions, 0 deletions
diff --git a/sysdeps/x86/cpu-features.c b/sysdeps/x86/cpu-features.c index aff894cc1e..35051d705e 100644 --- a/sysdeps/x86/cpu-features.c +++ b/sysdeps/x86/cpu-features.c @@ -80,6 +80,8 @@ init_cpu_features (struct cpu_features *cpu_features) case 0x57: /* Knights Landing. Enable Silvermont optimizations. */ + cpu_features->feature[index_Prefer_No_VZEROUPPER] + |= bit_Prefer_No_VZEROUPPER; case 0x37: case 0x4a: diff --git a/sysdeps/x86/cpu-features.h b/sysdeps/x86/cpu-features.h index 93bee69eaf..5e09a2ab05 100644 --- a/sysdeps/x86/cpu-features.h +++ b/sysdeps/x86/cpu-features.h @@ -34,6 +34,7 @@ #define bit_I586 (1 << 14) #define bit_I686 (1 << 15) #define bit_Prefer_MAP_32BIT_EXEC (1 << 16) +#define bit_Prefer_No_VZEROUPPER (1 << 17) /* CPUID Feature flags. */ @@ -99,6 +100,8 @@ # define index_I586 FEATURE_INDEX_1*FEATURE_SIZE # define index_I686 FEATURE_INDEX_1*FEATURE_SIZE # define index_Prefer_MAP_32BIT_EXEC FEATURE_INDEX_1*FEATURE_SIZE +# define index_Prefer_No_VZEROUPPER FEATURE_INDEX_1*FEATURE_SIZE + # if defined (_LIBC) && !IS_IN (nonlib) # ifdef __x86_64__ @@ -251,6 +254,7 @@ extern const struct cpu_features *__get_cpu_features (void) # define index_I586 FEATURE_INDEX_1 # define index_I686 FEATURE_INDEX_1 # define index_Prefer_MAP_32BIT_EXEC FEATURE_INDEX_1 +# define index_Prefer_No_VZEROUPPER FEATURE_INDEX_1 #endif /* !__ASSEMBLER__ */ |