summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Support/Host.cpp
diff options
context:
space:
mode:
authorCraig Topper <craig.topper@intel.com>2019-11-18 11:31:17 -0800
committerCraig Topper <craig.topper@intel.com>2019-11-18 11:57:04 -0800
commitff75bf6ac93a9ef5a7d41f7645e02fde3e968ce1 (patch)
treef01bda05ce751fae5a66c0d85eeb74a1f57138c5 /llvm/lib/Support/Host.cpp
parentd4e1ba3fa9dfec2613bdcc7db0b58dea490c56b1 (diff)
downloadbcm5719-llvm-ff75bf6ac93a9ef5a7d41f7645e02fde3e968ce1.tar.gz
bcm5719-llvm-ff75bf6ac93a9ef5a7d41f7645e02fde3e968ce1.zip
[X86] Add AMD Matisse (znver2) model number to getHostCPUName and compiler-rt's getAMDProcessorTypeAndSubtype.
This is the CPUID model used on Ryzen 3000 series (Zen 2/Matisse) CPUs. Patch by Alex James Differential Revision: https://reviews.llvm.org/D70279
Diffstat (limited to 'llvm/lib/Support/Host.cpp')
-rw-r--r--llvm/lib/Support/Host.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/Support/Host.cpp b/llvm/lib/Support/Host.cpp
index a4ab6530d7f..386446c76a0 100644
--- a/llvm/lib/Support/Host.cpp
+++ b/llvm/lib/Support/Host.cpp
@@ -959,9 +959,9 @@ static void getAMDProcessorTypeAndSubtype(unsigned Family, unsigned Model,
break; // "btver2"
case 23:
*Type = X86::AMDFAM17H;
- if (Model >= 0x30 && Model <= 0x3f) {
+ if ((Model >= 0x30 && Model <= 0x3f) || Model == 0x71) {
*Subtype = X86::AMDFAM17H_ZNVER2;
- break; // "znver2"; 30h-3fh: Zen2
+ break; // "znver2"; 30h-3fh, 71h: Zen2
}
if (Model <= 0x0f) {
*Subtype = X86::AMDFAM17H_ZNVER1;
OpenPOWER on IntegriCloud