From b2bbc1ed23a688b46b0697f14177d56e5fb38361 Mon Sep 17 00:00:00 2001 From: The Tumultuous Unicorn Of Darkness Date: Sun, 25 Aug 2024 20:01:30 +0200 Subject: [PATCH] DB: add AMD Strix Point --- libcpuid/libcpuid_internal.h | 1 + libcpuid/recog_amd.c | 10 +++++++++- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/libcpuid/libcpuid_internal.h b/libcpuid/libcpuid_internal.h index 9139a44..fe23e68 100644 --- a/libcpuid/libcpuid_internal.h +++ b/libcpuid/libcpuid_internal.h @@ -184,6 +184,7 @@ enum _amd_bits_t { _APU_ = LBIT( 26 ), C86_ = LBIT( 27 ), _Z = LBIT( 28 ), + _AI_ = LBIT( 29 ), }; typedef enum _amd_bits_t amd_bits_t; diff --git a/libcpuid/recog_amd.c b/libcpuid/recog_amd.c index 45579bd..a700694 100644 --- a/libcpuid/recog_amd.c +++ b/libcpuid/recog_amd.c @@ -382,6 +382,10 @@ const struct match_entry_t cpudb_amd[] = { { 15, -1, -1, 25, 117, -1, -1, -1, NC, RYZEN_|_5|_H , 0, "Ryzen 5 (Hawk Point)" }, { 15, -1, -1, 25, 117, -1, -1, -1, NC, RYZEN_|_5|_U , 0, "Ryzen 5 (Hawk Point)" }, { 15, -1, -1, 25, 117, -1, -1, -1, NC, RYZEN_|_3|_U , 0, "Ryzen 3 (Hawk Point)" }, + /* Zen 5 (2024) => https://en.wikichip.org/wiki/amd/microarchitectures/zen_5 */ + /* => Strix Point (Zen 5/RDNA3.5/XDNA2 based) */ + { 15, -1, -1, 26, 36, -1, -1, -1, NC, RYZEN_|_AI_|_9 , 0, "Ryzen AI 9 (Strix Point)" }, + { 15, -1, -1, 26, 36, -1, -1, -1, NC, RYZEN_|_AI_|_7 , 0, "Ryzen AI 7 (Strix Point)" }, /* F M S EF EM #cores L2$ L3$ BC ModelBits ModelCode Name */ }; @@ -587,9 +591,13 @@ static struct amd_code_and_bits_t decode_amd_codename_part1(const char *bs) if (amd_has_turion_modelname(bs)) { bits |= TURION_; } - if ((i = match_pattern(bs, "Ryzen [3579Z]")) != 0) { + if (((i = match_pattern(bs, "Ryzen [3579Z]")) != 0) || ((i = match_pattern(bs, "Ryzen AI [3579]")) != 0)) { bits |= RYZEN_; i--; + if ((bs[i + 6] == 'A') && (bs[i + 7] == 'I')) { + bits |= _AI_; + i += 3; // "AI " offset + } switch (bs[i + 6]) { case '3': bits |= _3; break; case '5': bits |= _5; break;