diff options
author | Craig Topper <craig.topper@intel.com> | 2019-05-31 19:18:07 +0000 |
---|---|---|
committer | Craig Topper <craig.topper@intel.com> | 2019-05-31 19:18:07 +0000 |
commit | c669629e6c01aa55f17f91e64905aac397f1f540 (patch) | |
tree | 48d549b80747f3846192274a09d67a46ef707322 /llvm/lib/Support/Host.cpp | |
parent | 5594ee0a3e2ba9ef67e92f69b6291f1895962fe1 (diff) | |
download | bcm5719-llvm-c669629e6c01aa55f17f91e64905aac397f1f540.tar.gz bcm5719-llvm-c669629e6c01aa55f17f91e64905aac397f1f540.zip |
[X86] Resync Host.cpp with compiler-rt's cpu_model.c to enable 0x55 to be identified as cascadelake when avx512vnni is detected.
Some other formatting changes.
llvm-svn: 362256
Diffstat (limited to 'llvm/lib/Support/Host.cpp')
-rw-r--r-- | llvm/lib/Support/Host.cpp | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/llvm/lib/Support/Host.cpp b/llvm/lib/Support/Host.cpp index 1aa2b82ce60..221a0af76d1 100644 --- a/llvm/lib/Support/Host.cpp +++ b/llvm/lib/Support/Host.cpp @@ -661,10 +661,10 @@ getIntelProcessorTypeAndSubtype(unsigned Family, unsigned Model, break; // Skylake: - case 0x4e: // Skylake mobile - case 0x5e: // Skylake desktop - case 0x8e: // Kaby Lake mobile - case 0x9e: // Kaby Lake desktop + case 0x4e: // Skylake mobile + case 0x5e: // Skylake desktop + case 0x8e: // Kaby Lake mobile + case 0x9e: // Kaby Lake desktop *Type = X86::INTEL_COREI7; // "skylake" *Subtype = X86::INTEL_COREI7_SKYLAKE; break; @@ -672,7 +672,10 @@ getIntelProcessorTypeAndSubtype(unsigned Family, unsigned Model, // Skylake Xeon: case 0x55: *Type = X86::INTEL_COREI7; - *Subtype = X86::INTEL_COREI7_SKYLAKE_AVX512; // "skylake-avx512" + if (Features2 & (1 << (X86::FEATURE_AVX512VNNI - 32))) + *Subtype = X86::INTEL_COREI7_CASCADELAKE; // "cascadelake" + else + *Subtype = X86::INTEL_COREI7_SKYLAKE_AVX512; // "skylake-avx512" break; // Cannonlake: @@ -723,9 +726,11 @@ getIntelProcessorTypeAndSubtype(unsigned Family, unsigned Model, case 0x86: *Type = X86::INTEL_TREMONT; break; + case 0x57: *Type = X86::INTEL_KNL; // knl break; + case 0x85: *Type = X86::INTEL_KNM; // knm break; |