Message ID | 20241031085233.425388-8-tao1.su@linux.intel.com (mailing list archive) |
---|---|
State | New |
Headers | show |
Series | Add AVX10.1 CPUID support and GraniteRapids-v2 model | expand |
diff --git a/target/i386/cpu.c b/target/i386/cpu.c index d8d86edd67..cc7e4ce665 100644 --- a/target/i386/cpu.c +++ b/target/i386/cpu.c @@ -7123,7 +7123,15 @@ static bool cpuid_has_xsave_feature(CPUX86State *env, const ExtSaveArea *esa) return false; } - return (env->features[esa->feature] & esa->bits); + if (env->features[esa->feature] & esa->bits) { + return true; + } + if (esa->feature == FEAT_7_0_EBX && esa->bits == CPUID_7_0_EBX_AVX512F + && (env->features[FEAT_7_1_EDX] & CPUID_7_1_EDX_AVX10)) { + return true; + } + + return false; } static void x86_cpu_reset_hold(Object *obj, ResetType type)