util/cpu_detect: add/guess support for next Zen CPUs

so that we don't have to update this anymore

Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12335>
This commit is contained in:
Marek Olšák 2021-08-10 12:09:57 -04:00 committed by Marge Bot
parent d7a36d8907
commit 386e5371a7
2 changed files with 4 additions and 0 deletions

View file

@ -709,6 +709,9 @@ util_cpu_detect_once(void)
case 0x19:
util_cpu_caps.family = CPU_AMD_ZEN3;
break;
default:
if (util_cpu_caps.x86_cpu_type > 0x19)
util_cpu_caps.family = CPU_AMD_ZEN_NEXT;
}
/* general feature flags */

View file

@ -50,6 +50,7 @@ enum cpu_family {
CPU_AMD_ZEN1_ZEN2,
CPU_AMD_ZEN_HYGON,
CPU_AMD_ZEN3,
CPU_AMD_ZEN_NEXT,
CPU_AMD_LAST,
};