diff --git a/qemu/tests/cfg/x86_cpu_model.cfg b/qemu/tests/cfg/x86_cpu_model.cfg index 703d171051e9f068ec5fb888e6f0442797de980d..cf2e6b12179ae9a4a730bd12af05ed3d7abbb74e 100644 --- a/qemu/tests/cfg/x86_cpu_model.cfg +++ b/qemu/tests/cfg/x86_cpu_model.cfg @@ -27,30 +27,52 @@ - Icelake-Server: flags = "la57 wbnoinvd avx512vbmi umip avx512_vbmi2 gfni vaes vpclmulqdq avx512_bitalg avx512_vpopcntdq clflushopt pdpe1gb clwb avx512f avx512dq avx512bw avx512cd avx512vl" model_pattern = "Intel Xeon Processor \(Icelake%s\)" + - Icelake-Server-noTSX: + flags = "la57 wbnoinvd avx512vbmi umip avx512_vbmi2 gfni vaes vpclmulqdq avx512_bitalg avx512_vpopcntdq clflushopt pdpe1gb clwb avx512f avx512dq avx512bw avx512cd avx512vl" + model_pattern = "Intel Xeon Processor \(Icelake%s\)" + no_flags = "hle rtm" - Icelake-Client: flags = "wbnoinvd avx512vbmi umip avx512_vbmi2 gfni vaes vpclmulqdq avx512_bitalg avx512_vpopcntdq" model_pattern = "Intel Core Processor \(Icelake%s\)" + - Icelake-Client-noTSX: + flags = "wbnoinvd avx512vbmi umip avx512_vbmi2 gfni vaes vpclmulqdq avx512_bitalg avx512_vpopcntdq" + model_pattern = "Intel Core Processor \(Icelake%s\)" + no_flags = "hle rtm" - Cascadelake-Server: flags = "avx512_vnni clflushopt ibrs ibpb pdpe1gb clwb avx512f avx512dq avx512bw avx512cd avx512vl" model_pattern = "Intel Xeon Processor \(Cascadelake%s\)" + - Cascadelake-Server-noTSX: + flags = "avx512_vnni clflushopt ibrs ibpb pdpe1gb clwb avx512f avx512dq avx512bw avx512cd avx512vl" + model_pattern = "Intel Xeon Processor \(Cascadelake%s\)" + no_flags = "hle rtm" - Skylake-Server: flags = "pdpe1gb clwb avx512f avx512dq avx512bw avx512cd avx512vl" model_pattern = "Intel Xeon Processor \(Skylake%s\)" + - Skylake-Server-noTSX: + flags = "pdpe1gb clwb avx512f avx512dq avx512bw avx512cd avx512vl" + model_pattern = "Intel Xeon Processor \(Skylake%s\)" + no_flags = "hle rtm" - Skylake-Client: flags = "xsavec xgetbv1" model_pattern = "Intel Core Processor \(Skylake%s\)" + - Skylake-Client-noTSX: + flags = "xsavec xgetbv1" + model_pattern = "Intel Core Processor \(Skylake%s\)" + no_flags = "hle rtm" - Broadwell: flags = "adx rdseed 3dnowprefetch smap hle rtm" model_pattern = "Intel Core Processor \(Broadwell%s\)" - Broadwell-noTSX: flags = "adx rdseed 3dnowprefetch smap" model_pattern = "Intel Core Processor \(Broadwell, no TSX%s\)" + no_flags = "hle rtm" - Haswell: flags = "vme sse2 sse fxsr mmx clflush pse36 pat cmov mca pge mtrr sep apic cx8 mce pae msr tsc pse de fpu avx xsave aes tsc_deadline_timer fma movbe popcnt x2apic sse4_2 sse4_1 cx16 ssse3 pclmulqdq pni f16c rdrand fsgsbase bmi1 hle avx2 smep bmi2 erms invpcid rtm lm rdtscp nx syscall lahf_lm xsaveopt arat pcid" model_pattern = "Intel Core Processor \(Haswell%s\)" - Haswell-noTSX: flags = "vme sse2 sse fxsr mmx clflush pse36 pat cmov mca pge mtrr sep apic cx8 mce pae msr tsc pse de fpu avx xsave aes tsc_deadline_timer fma movbe popcnt x2apic sse4_2 sse4_1 cx16 ssse3 pclmulqdq pni f16c rdrand fsgsbase bmi1 avx2 smep bmi2 erms invpcid lm rdtscp nx syscall lahf_lm xsaveopt arat pcid" model_pattern = "Intel Core Processor \(Haswell, no TSX%s\)" + no_flags = "hle rtm" - IvyBridge: flags = "vme sse2 sse fxsr mmx clflush pse36 pat cmov mca pge mtrr sep apic cx8 mce pae msr tsc pse de fpu avx xsave aes tsc_deadline_timer popcnt x2apic sse4_2 sse4_1 cx16 ssse3 pclmulqdq pni rdrand fsgsbase smep erms lm rdtscp nx syscall lahf_lm xsaveopt arat f16c" model_pattern = "Intel Xeon E3-12xx v2 \(Ivy Bridge%s\)" diff --git a/qemu/tests/x86_cpu_model.py b/qemu/tests/x86_cpu_model.py index 304353113beae5347be82fd505cd78d46e26a8fd..53f626188a5f01d46577b33242239d934ea6fb8e 100644 --- a/qemu/tests/x86_cpu_model.py +++ b/qemu/tests/x86_cpu_model.py @@ -78,6 +78,11 @@ def run(test, params, env): missing = [f for f in flags.split() if f not in out] if missing: test.fail("Flag %s not in guest" % missing) + no_flags = params.get("no_flags") + if no_flags: + err_flags = [f for f in no_flags.split() if f in out] + if err_flags: + test.fail("Flag %s should not be present in guest" % err_flags) if params.get("reboot_method"): error_context.context("Reboot guest '%s'." % vm.name, logging.info)