aboutsummaryrefslogtreecommitdiff
path: root/module-common.c
diff options
context:
space:
mode:
authorTao Su <tao1.su@linux.intel.com>2024-10-31 16:52:31 +0800
committerPaolo Bonzini <pbonzini@redhat.com>2024-10-31 18:28:33 +0100
commit150ab84b2d0083e6af344cca70290614d4fe568d (patch)
treee901f0bb5aae4476352e52ec0e052cc112438d20 /module-common.c
parent2d055b8fe11ee567c2ae8047311fd83697e494b6 (diff)
downloadqemu-150ab84b2d0083e6af344cca70290614d4fe568d.zip
qemu-150ab84b2d0083e6af344cca70290614d4fe568d.tar.gz
qemu-150ab84b2d0083e6af344cca70290614d4fe568d.tar.bz2
target/i386: Add feature dependencies for AVX10
Since the highest supported vector length for a processor implies that all lesser vector lengths are also supported, add the dependencies of the supported vector lengths. If all vector lengths aren't supported, clear AVX10 enable bit as well. Note that the order of AVX10 related dependencies should be kept as: CPUID_24_0_EBX_AVX10_128 -> CPUID_24_0_EBX_AVX10_256, CPUID_24_0_EBX_AVX10_256 -> CPUID_24_0_EBX_AVX10_512, CPUID_24_0_EBX_AVX10_VL_MASK -> CPUID_7_1_EDX_AVX10, CPUID_7_1_EDX_AVX10 -> CPUID_24_0_EBX, so that prevent user from setting weird CPUID combinations, e.g. 256-bits and 512-bits are supported but 128-bits is not, no vector lengths are supported but AVX10 enable bit is still set. Since AVX10_128 will be reserved as 1, adding these dependencies has the bonus that when user sets -cpu host,-avx10-128, CPUID_7_1_EDX_AVX10 and CPUID_24_0_EBX will be disabled automatically. Tested-by: Xuelian Guo <xuelian.guo@intel.com> Signed-off-by: Tao Su <tao1.su@linux.intel.com> Link: https://lore.kernel.org/r/20241028024512.156724-5-tao1.su@linux.intel.com Reviewed-by: Zhao Liu <zhao1.liu@intel.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Link: https://lore.kernel.org/r/20241031085233.425388-7-tao1.su@linux.intel.com Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'module-common.c')
0 files changed, 0 insertions, 0 deletions