[llvm] [X86] Add AMD Llano family detection (PR #111312)

via llvm-commits llvm-commits at lists.llvm.org
Sun Oct 6 14:12:41 PDT 2024


https://github.com/RipleyTom created https://github.com/llvm/llvm-project/pull/111312

Very simple one liner, adds the missing detection for the Llano family which is essentially a refreshed K10:
Documentation of the family id: https://en.wikichip.org/wiki/amd/cpuid#Family_18_.2812h.29
Documentation that it fits into amdfam10: https://en.wikipedia.org/wiki/AMD_10h#12h


>From 79fd127abb56b16278e6503ec4e00696026f4d14 Mon Sep 17 00:00:00 2001
From: RipleyTom <RipleyTom at users.noreply.github.com>
Date: Sun, 6 Oct 2024 22:57:34 +0200
Subject: [PATCH] [X86] Add AMD Llano family detection

---
 llvm/lib/TargetParser/Host.cpp | 1 +
 1 file changed, 1 insertion(+)

diff --git a/llvm/lib/TargetParser/Host.cpp b/llvm/lib/TargetParser/Host.cpp
index 6e175f25c4882c..6e1f4b6052bda8 100644
--- a/llvm/lib/TargetParser/Host.cpp
+++ b/llvm/lib/TargetParser/Host.cpp
@@ -1050,6 +1050,7 @@ static const char *getAMDProcessorTypeAndSubtype(unsigned Family,
     CPU = "k8";
     break;
   case 16:
+  case 18:
     CPU = "amdfam10";
     *Type = X86::AMDFAM10H; // "amdfam10"
     switch (Model) {



More information about the llvm-commits mailing list