diff --git a/virttest/cpu.py b/virttest/cpu.py index 5120dfce91..2a54ec69c9 100644 --- a/virttest/cpu.py +++ b/virttest/cpu.py @@ -45,56 +45,167 @@ CPU_TYPES = { "AuthenticAMD": [ + "EPYC-Genoa-v1", "EPYC-Genoa", + "EPYC-Milan-v2", + "EPYC-Milan-v1", "EPYC-Milan", + "EPYC-Rome-v4", + "EPYC-Rome-v3", + "EPYC-Rome-v2", + "EPYC-Rome-v1", "EPYC-Rome", + "EPYC-v4", + "EPYC-v3", + "EPYC-v2", + "EPYC-IBPB", + "EPYC-v1", "EPYC", + "Opteron_G5-v1", "Opteron_G5", + "Opteron_G4-v1", "Opteron_G4", + "Opteron_G3-v1", "Opteron_G3", + "Opteron_G2-v1", "Opteron_G2", + "Opteron_G1-v1", "Opteron_G1", ], "GenuineIntel": [ + "SapphireRapids-v2", + "SapphireRapids-v1", "SapphireRapids", + "Snowridge-v4", + "Snowridge-v3", + "Snowridge-v2", + "Snowridge-v1", "Snowridge", + "Cooperlake-v2", + "Cooperlake-v1", "Cooperlake", - "Icelake-Server", + "Icelake-Server-v7", + "Icelake-Server-v6", + "Icelake-Server-v5", + "Icelake-Server-v4", + "Icelake-Server-v3", + "Icelake-Server-v2", "Icelake-Server-noTSX", + "Icelake-Server-v1", + "Icelake-Server", "Icelake-Client", "Icelake-Client-noTSX", - "Cascadelake-Server", + "Cascadelake-Server-v5", + "Cascadelake-Server-v4", + "Cascadelake-Server-v3", "Cascadelake-Server-noTSX", - "Skylake-Server", + "Cascadelake-Server-v2", + "Cascadelake-Server-v1", + "Cascadelake-Server", + "Skylake-Server-v5", + "Skylake-Server-v4", + "Skylake-Server-v3", "Skylake-Server-noTSX-IBRS", - "Skylake-Client", + "Skylake-Server-v2", + "Skylake-Server-IBRS", + "Skylake-Server-v1", + "Skylake-Server", + "Skylake-Client-v4", + "Skylake-Client-v3", "Skylake-Client-noTSX-IBRS", - "Broadwell", + "Skylake-Client-v2", + "Skylake-Client-IBRS", + "Skylake-Client-v1", + "Skylake-Client", + "Broadwell-v4", + "Broadwell-noTSX-IBRS", + "Broadwell-v3", + "Broadwell-IBRS", + "Broadwell-v2", "Broadwell-noTSX", + "Broadwell-v1", + "Broadwell", + "Haswell-v4", + "Haswell-noTSX-IBRS", + "Haswell-v3", + "Haswell-IBRS", + "Haswell-v2", + "Haswell-noTSX", + "Haswell-v1", "Haswell", "Haswell-noTSX", + "IvyBridge-v2", + "IvyBridge-IBRS", + "IvyBridge-v1", "IvyBridge", + "SandyBridge-v2", + "SandyBridge-IBRS", + "SandyBridge-v1", "SandyBridge", + "Westmere-v2", + "Westmere-IBRS", + "Westmere-v1", "Westmere", + "Nehalem-v2", + "Nehalem-IBRS", + "Nehalem-v1", "Nehalem", + "Penryn-v1", "Penryn", + "Conroe-v1", "Conroe", ], } CPU_TYPES_RE = { + "EPYC-Genoa-v1": "la57,vnmi,avx512f,avx512dq,avx512ifma,avx512cd," + "avx512bw,avx512vl,avx512vbmi,avx512_vbmi2,gfni,avx512_vnni," + "avx512_bitalg,avx512_vpopcntdq,avx512_bf16", "EPYC-Genoa": "la57,vnmi,avx512f,avx512dq,avx512ifma,avx512cd," "avx512bw,avx512vl,avx512vbmi,avx512_vbmi2,gfni,avx512_vnni," "avx512_bitalg,avx512_vpopcntdq,avx512_bf16", + "EPYC-Milan-v2": "ibrs,pcid,ssbd,erms,fsrm,invpcid,pku,vaes,vpclmulqdq", + "EPYC-Milan-v1": "ibrs,pcid,ssbd,erms,fsrm,invpcid,pku", "EPYC-Milan": "ibrs,pcid,ssbd,erms,fsrm,invpcid,pku", - "EPYC-Rome": "rdpid,wbnoinvd,stibp,clwb,umip", + "EPYC-Rome-v4": "rdpid,wbnoinvd,stibp,clwb,umip", + "EPYC-Rome-v3": "rdpid,wbnoinvd,stibp,clwb,umip,xsaves", + "EPYC-Rome-v2": "rdpid,wbnoinvd,stibp,clwb,umip,xsaves,ibrs", + "EPYC-Rome-v1": "rdpid,wbnoinvd,stibp,clwb,umip,xsaves", + "EPYC-Rome": "rdpid,wbnoinvd,stibp,clwb,umip,xsaves", + "EPYC-v4": "avx2,adx,bmi2,sha_ni,ibpb,perfctr_core,clzero,xsaveerptr,xsaves", + "EPYC-v3": "avx2,adx,bmi2,sha_ni,ibpb,perfctr_core,clzero,xsaveerptr,xsaves", + "EPYC-v2": "avx2,adx,bmi2,sha_ni,ibpb", + "EPYC-IBPB": "avx2,adx,bmi2,sha_ni,ibpb", + "EPYC-v1": "avx2,adx,bmi2,sha_ni", "EPYC": "avx2,adx,bmi2,sha_ni", + "Opteron_G5-v1": "f16c,fma4,xop,tbm", "Opteron_G5": "f16c,fma4,xop,tbm", + "Opteron_G4-v1": ( + "fma4,xop,avx,xsave,aes,sse4.2|sse4_2," "sse4.1|sse4_1,cx16,ssse3,sse4a" + ), "Opteron_G4": ( "fma4,xop,avx,xsave,aes,sse4.2|sse4_2," "sse4.1|sse4_1,cx16,ssse3,sse4a" ), + "Opteron_G3-v1": "cx16,sse4a", "Opteron_G3": "cx16,sse4a", + "Opteron_G2-v1": "cx16", "Opteron_G2": "cx16", + "Opteron_G1-v1": "", "Opteron_G1": "", + "SapphireRapids-v3": ( + "serialize,tsxldtrk|tsx-ldtrk,amx_bf16," + "amx_tile,amx_int8,avx512_bf16,avx_vnni," + "avx512_fp16,hle,rtm,taa-no,ss,tsc_adjust,cldemote,movdiri,movdir64b" + ), + "SapphireRapids-v2": ( + "serialize,tsxldtrk|tsx-ldtrk,amx_bf16," + "amx_tile,amx_int8,avx512_bf16,avx_vnni," + "avx512_fp16,hle,rtm,taa-no" + ), + "SapphireRapids-v1": ( + "serialize,tsxldtrk|tsx-ldtrk,amx_bf16," + "amx_tile,amx_int8,avx512_bf16,avx_vnni," + "avx512_fp16,hle,rtm,taa-no" + ), "SapphireRapids": ( "serialize,tsxldtrk|tsx-ldtrk,amx_bf16," "amx_tile,amx_int8,avx512_bf16,avx_vnni," @@ -102,8 +213,27 @@ ), "Snowridge": "split_lock_detect,gfni,movdiri,movdiri64b,cldemote", "Cooperlake": "avx512_bf16,stibp,arch_capabilities,hle,rtm", - "Icelake-Server": "avx512_vnni,la57,clflushopt,hle,rtm", + "Icelake-Server-v7": ( + "avx512_vnni,la57,clflushopt,hle,rtm,arch_capabilities," + "taa-no,xsaves,sha_ni,avx512ifma,rdpid,fsrm" + ), + "Icelake-Server-v6": ( + "avx512_vnni,la57,clflushopt,arch_capabilities," + "taa-no,xsaves,sha_ni,avx512ifma,rdpid,fsrm" + ), + "Icelake-Server-v5": ( + "avx512_vnni,la57,clflushopt,arch_capabilities," + "taa-no,xsaves,sha_ni,avx512ifma,rdpid,fsrm" + ), + "Icelake-Server-v4": ( + "avx512_vnni,la57,clflushopt,arch_capabilities," + "taa-no,sha_ni,avx512ifma,rdpid,fsrm" + ), + "Icelake-Server-v3": "avx512_vnni,la57,clflushopt,arch_capabilities,taa-no", + "Icelake-Server-v2": "avx512_vnni,la57,clflushopt", "Icelake-Server-noTSX": "avx512_vnni,la57,clflushopt", + "Icelake-Server-v1": "avx512_vnni,la57,clflushopt,hle,rtm", + "Icelake-Server": "avx512_vnni,la57,clflushopt,hle,rtm", "Icelake-Client": ( "avx512_vpopcntdq|avx512-vpopcntdq," "avx512vbmi,avx512_vbmi2|avx512vbmi2,hle,rtm" @@ -114,25 +244,82 @@ "avx512vbmi,avx512_vbmi2|avx512vbmi2," "gfni,vaes,vpclmulqdq,avx512_vnni" ), - "Cascadelake-Server": ( - "avx512f,avx512dq,avx512bw,avx512cd," "avx512vl,clflushopt,avx512_vnni,hle,rtm" + "Cascadelake-Server-v5": ( + "avx512f,avx512dq,avx512bw,avx512cd,avx512vl," + "clflushopt,avx512_vnni,xsaves,arch_capabilities" + ), + "Cascadelake-Server-v4": ( + "avx512f,avx512dq,avx512bw,avx512cd,avx512vl," + "clflushopt,avx512_vnni,arch_capabilities" + ), + "Cascadelake-Server-v3": ( + "avx512f,avx512dq,avx512bw,avx512cd,avx512vl," + "clflushopt,avx512_vnni,arch_capabilities" ), "Cascadelake-Server-noTSX": ( - "avx512f,avx512dq,avx512bw,avx512cd," "avx512vl,clflushopt,avx512_vnni" + "avx512f,avx512dq,avx512bw,avx512cd,avx512vl," + "clflushopt,avx512_vnni,arch_capabilities" ), - "Skylake-Server": "avx512f,clwb,xgetbv1,pcid,hle,rtm", + "Cascadelake-Server-v2": ( + "avx512f,avx512dq,avx512bw,avx512cd,avx512vl," + "clflushopt,avx512_vnni,hle,rtm,arch_capabilities" + ), + "Cascadelake-Server-v1": ( + "avx512f,avx512dq,avx512bw,avx512cd,avx512vl," "clflushopt,avx512_vnni,hle,rtm" + ), + "Cascadelake-Server": ( + "avx512f,avx512dq,avx512bw,avx512cd,avx512vl," "clflushopt,avx512_vnni,hle,rtm" + ), + "Skylake-Server-v5": "avx512f,clwb,xgetbv1,pcid,xsaves", + "Skylake-Server-v4": "avx512f,clwb,xgetbv1,pcid", + "Skylake-Server-v3": "avx512f,clwb,xgetbv1,pcid", "Skylake-Server-noTSX-IBRS": "avx512f,clwb,xgetbv1,pcid", - "Skylake-Client": "xgetbv1,pcid,hle,rtm", + "Skylake-Server-v2": "avx512f,clwb,xgetbv1,pcid,hle,rtm", + "Skylake-Server-IBRS": "avx512f,clwb,xgetbv1,pcid,hle,rtm", + "Skylake-Server-v1": "avx512f,clwb,xgetbv1,pcid,hle,rtm", + "Skylake-Server": "avx512f,clwb,xgetbv1,pcid,hle,rtm", + "Skylake-Client-v4": "xgetbv1,pcid,xsaves", + "Skylake-Client-v3": "xgetbv1,pcid", "Skylake-Client-noTSX-IBRS": "xgetbv1,pcid", - "Broadwell": "adx,rdseed,3dnowprefetch,hle,rtm", + "Skylake-Client-v2": "xgetbv1,pcid,hle,rtm", + "Skylake-Client-IBRS": "xgetbv1,pcid,hle,rtm", + "Skylake-Client-v1": "xgetbv1,pcid,hle,rtm", + "Skylake-Client": "xgetbv1,pcid,hle,rtm", + "Broadwell-v4": "adx,rdseed,3dnowprefetch", + "Broadwell-noTSX-IBRS": "adx,rdseed,3dnowprefetch", + "Broadwell-v3": "adx,rdseed,3dnowprefetch,hle,rtm", + "Broadwell-IBRS": "adx,rdseed,3dnowprefetch,hle,rtm", + "Broadwell-v2": "adx,rdseed,3dnowprefetch", "Broadwell-noTSX": "adx,rdseed,3dnowprefetch", - "Haswell": "fma,avx2,movbe,hle,rtm", + "Broadwell-v1": "adx,rdseed,3dnowprefetch,hle,rtm", + "Broadwell": "adx,rdseed,3dnowprefetch,hle,rtm", + "Haswell-v4": "fma,avx2,movbe", + "Haswell-noTSX-IBRS": "fma,avx2,movbe", + "Haswell-v3": "fma,avx2,movbe,hle,rtm", + "Haswell-IBRS": "fma,avx2,movbe,hle,rtm", + "Haswell-v2": "fma,avx2,movbe", "Haswell-noTSX": "fma,avx2,movbe", + "Haswell-v1": "fma,avx2,movbe,hle,rtm", + "Haswell": "fma,avx2,movbe,hle,rtm", + "IvyBridge-v2": "f16c,fsgsbase,erms", + "IvyBridge-IBRS": "f16c,fsgsbase,erms", + "IvyBridge-v1": "f16c,fsgsbase,erms", "IvyBridge": "f16c,fsgsbase,erms", - "SandyBridge": ("avx,xsave,aes,sse4_2|sse4.2,sse4.1|sse4_1," "cx16,ssse3"), + "SandyBridge-v2": "avx,xsave,aes,sse4_2|sse4.2,sse4.1|sse4_1,cx16,ssse3", + "SandyBridge-IBRS": "avx,xsave,aes,sse4_2|sse4.2,sse4.1|sse4_1,cx16,ssse3", + "SandyBridge-v1": "avx,xsave,aes,sse4_2|sse4.2,sse4.1|sse4_1,cx16,ssse3", + "SandyBridge": "avx,xsave,aes,sse4_2|sse4.2,sse4.1|sse4_1,cx16,ssse3", + "Westmere-v2": "aes,sse4.2|sse4_2,sse4.1|sse4_1,cx16,ssse3", + "Westmere-IBRS": "aes,sse4.2|sse4_2,sse4.1|sse4_1,cx16,ssse3", + "Westmere-v1": "aes,sse4.2|sse4_2,sse4.1|sse4_1,cx16,ssse3", "Westmere": "aes,sse4.2|sse4_2,sse4.1|sse4_1,cx16,ssse3", + "Nehalem-v2": "sse4.2|sse4_2,sse4.1|sse4_1,cx16,ssse3", + "Nehalem-IBRS": "sse4.2|sse4_2,sse4.1|sse4_1,cx16,ssse3", + "Nehalem-v1": "sse4.2|sse4_2,sse4.1|sse4_1,cx16,ssse3", "Nehalem": "sse4.2|sse4_2,sse4.1|sse4_1,cx16,ssse3", + "Penryn-v1": "sse4.1|sse4_1,cx16,ssse3", "Penryn": "sse4.1|sse4_1,cx16,ssse3", + "Conroe-v1": "ssse3", "Conroe": "ssse3", }