|
|
9ae3a8 |
From 4f2a39dd988cfae0210dfa7a84be00617ba17bef Mon Sep 17 00:00:00 2001
|
|
|
9ae3a8 |
From: Eduardo Habkost <ehabkost@redhat.com>
|
|
|
9ae3a8 |
Date: Wed, 13 Dec 2017 15:43:41 -0200
|
|
|
9ae3a8 |
Subject: [PATCH 3/3] target-i386: cpu: add new CPU models for indirect branch
|
|
|
9ae3a8 |
predictor restrictions
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
RH-Author: Eduardo Habkost <ehabkost@redhat.com>
|
|
|
9ae3a8 |
Message-id: <20171213174341.20684-4-ehabkost@redhat.com>
|
|
|
9ae3a8 |
Patchwork-id: n/a
|
|
|
9ae3a8 |
O-Subject: [CONFIDENTIAL][RHEL-7.5 qemu-kvm PATCH v2 3/3] target-i386: cpu: add
|
|
|
9ae3a8 |
new CPU models for indirect branch predictor restrictions
|
|
|
9ae3a8 |
Bugzilla: CVE-2017-5715
|
|
|
9ae3a8 |
RH-Acked-by: Paolo Bonzini <pbonzini@redhat.com>
|
|
|
9ae3a8 |
RH-Acked-by: Miroslav Rezanina <mrezanin@redhat.com>
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
Changes v1 -> v2:
|
|
|
9ae3a8 |
* Copied the original CPU models from the same source file, just adding
|
|
|
9ae3a8 |
SPEC_CTRL and updating level/xlevel/model_id/stepping, to keep compatibility
|
|
|
9ae3a8 |
code exactly the same.
|
|
|
9ae3a8 |
* Update compat_props so we can be sure the same compat rules will apply to the
|
|
|
9ae3a8 |
original CPU models and to the *-IBRS ones
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
To ensure the New CPU models won't introduce any unexpected
|
|
|
9ae3a8 |
changes except for the spec-ctrl feature (even if people are
|
|
|
9ae3a8 |
running older machine-types), copy all compat_props entries for
|
|
|
9ae3a8 |
existing CPU models to their *-IBRS versions.
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
The only entries that are not being copied are the ones touching
|
|
|
9ae3a8 |
"(min-)level" and "(min-)xlevel" because it's an expected result
|
|
|
9ae3a8 |
of the CPU model change (otherwise the spec-ctrl feature would
|
|
|
9ae3a8 |
remain unavailable to the guest).
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
The entries that had to be copied can be found using:
|
|
|
9ae3a8 |
$ git grep -E 'Nehalem|Westmere|SandyBridge|IvyBridge|Haswell-noTSX|Haswell|Broadwell-noTSX|Broadwell|Skylake-Client|Skylake-Server|EPYC'
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
Note that the upstream-only PC_COMPAT_* macros are not being
|
|
|
9ae3a8 |
touched as they are not used by the RHEL machine-types.
|
|
|
9ae3a8 |
---
|
|
|
9ae3a8 |
hw/i386/pc_piix.c | 17 +++
|
|
|
9ae3a8 |
hw/i386/pc_q35.c | 1 +
|
|
|
9ae3a8 |
target-i386/cpu.c | 328 ++++++++++++++++++++++++++++++++++++++++++++++++++++++
|
|
|
9ae3a8 |
target-i386/cpu.h | 3 +
|
|
|
9ae3a8 |
4 files changed, 349 insertions(+)
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
diff --git a/hw/i386/pc_piix.c b/hw/i386/pc_piix.c
|
|
|
9ae3a8 |
index b043124..c53a6d4 100644
|
|
|
9ae3a8 |
--- a/hw/i386/pc_piix.c
|
|
|
9ae3a8 |
+++ b/hw/i386/pc_piix.c
|
|
|
9ae3a8 |
@@ -753,7 +753,9 @@ static void pc_compat_rhel700(QEMUMachineInitArgs *args)
|
|
|
9ae3a8 |
x86_cpu_compat_set_features("Conroe", FEAT_1_ECX, CPUID_EXT_X2APIC, 0);
|
|
|
9ae3a8 |
x86_cpu_compat_set_features("Penryn", FEAT_1_ECX, CPUID_EXT_X2APIC, 0);
|
|
|
9ae3a8 |
x86_cpu_compat_set_features("Nehalem", FEAT_1_ECX, CPUID_EXT_X2APIC, 0);
|
|
|
9ae3a8 |
+ x86_cpu_compat_set_features("Nehalem-IBRS", FEAT_1_ECX, CPUID_EXT_X2APIC, 0);
|
|
|
9ae3a8 |
x86_cpu_compat_set_features("Westmere", FEAT_1_ECX, CPUID_EXT_X2APIC, 0);
|
|
|
9ae3a8 |
+ x86_cpu_compat_set_features("Westmere-IBRS", FEAT_1_ECX, CPUID_EXT_X2APIC, 0);
|
|
|
9ae3a8 |
/* SandyBridge and Haswell already have x2apic enabled */
|
|
|
9ae3a8 |
x86_cpu_compat_set_features("Opteron_G1", FEAT_1_ECX, CPUID_EXT_X2APIC, 0);
|
|
|
9ae3a8 |
x86_cpu_compat_set_features("Opteron_G2", FEAT_1_ECX, CPUID_EXT_X2APIC, 0);
|
|
|
9ae3a8 |
@@ -928,18 +930,31 @@ static void pc_compat_rhel660(QEMUMachineInitArgs *args)
|
|
|
9ae3a8 |
x86_cpu_compat_set_features("Conroe", FEAT_1_ECX, CPUID_EXT_X2APIC, 0);
|
|
|
9ae3a8 |
x86_cpu_compat_set_features("Penryn", FEAT_1_ECX, CPUID_EXT_X2APIC, 0);
|
|
|
9ae3a8 |
x86_cpu_compat_set_features("Nehalem", FEAT_1_ECX, CPUID_EXT_X2APIC, 0);
|
|
|
9ae3a8 |
+ x86_cpu_compat_set_features("Nehalem-IBRS", FEAT_1_ECX, CPUID_EXT_X2APIC, 0);
|
|
|
9ae3a8 |
x86_cpu_compat_set_features("Westmere", FEAT_1_ECX, CPUID_EXT_X2APIC, 0);
|
|
|
9ae3a8 |
+ x86_cpu_compat_set_features("Westmere-IBRS", FEAT_1_ECX, CPUID_EXT_X2APIC, 0);
|
|
|
9ae3a8 |
x86_cpu_compat_set_features("Westmere", FEAT_1_ECX, 0, CPUID_EXT_PCLMULQDQ);
|
|
|
9ae3a8 |
+ x86_cpu_compat_set_features("Westmere-IBRS", FEAT_1_ECX, 0, CPUID_EXT_PCLMULQDQ);
|
|
|
9ae3a8 |
x86_cpu_compat_set_features("Westmere", FEAT_8000_0001_EDX,
|
|
|
9ae3a8 |
CPUID_EXT2_FXSR | CPUID_EXT2_MMX | CPUID_EXT2_PAT |
|
|
|
9ae3a8 |
CPUID_EXT2_CMOV | CPUID_EXT2_PGE | CPUID_EXT2_APIC |
|
|
|
9ae3a8 |
CPUID_EXT2_CX8 | CPUID_EXT2_MCE | CPUID_EXT2_PAE | CPUID_EXT2_MSR |
|
|
|
9ae3a8 |
CPUID_EXT2_TSC | CPUID_EXT2_PSE | CPUID_EXT2_DE | CPUID_EXT2_FPU,
|
|
|
9ae3a8 |
0);
|
|
|
9ae3a8 |
+ x86_cpu_compat_set_features("Westmere-IBRS", FEAT_8000_0001_EDX,
|
|
|
9ae3a8 |
+ CPUID_EXT2_FXSR | CPUID_EXT2_MMX | CPUID_EXT2_PAT |
|
|
|
9ae3a8 |
+ CPUID_EXT2_CMOV | CPUID_EXT2_PGE | CPUID_EXT2_APIC |
|
|
|
9ae3a8 |
+ CPUID_EXT2_CX8 | CPUID_EXT2_MCE | CPUID_EXT2_PAE | CPUID_EXT2_MSR |
|
|
|
9ae3a8 |
+ CPUID_EXT2_TSC | CPUID_EXT2_PSE | CPUID_EXT2_DE | CPUID_EXT2_FPU,
|
|
|
9ae3a8 |
+ 0);
|
|
|
9ae3a8 |
x86_cpu_compat_set_features("Broadwell", FEAT_8000_0001_EDX,
|
|
|
9ae3a8 |
0, CPUID_EXT2_RDTSCP);
|
|
|
9ae3a8 |
+ x86_cpu_compat_set_features("Broadwell-IBRS", FEAT_8000_0001_EDX,
|
|
|
9ae3a8 |
+ 0, CPUID_EXT2_RDTSCP);
|
|
|
9ae3a8 |
x86_cpu_compat_set_features("Broadwell", FEAT_7_0_EBX,
|
|
|
9ae3a8 |
0, CPUID_7_0_EBX_SMAP);
|
|
|
9ae3a8 |
+ x86_cpu_compat_set_features("Broadwell-IBRS", FEAT_7_0_EBX,
|
|
|
9ae3a8 |
+ 0, CPUID_7_0_EBX_SMAP);
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
/* RHEL-6 kernel never supported exposing RDTSCP */
|
|
|
9ae3a8 |
x86_cpu_compat_set_features(NULL, FEAT_8000_0001_EDX, 0, CPUID_EXT2_RDTSCP);
|
|
|
9ae3a8 |
@@ -1122,6 +1137,8 @@ static void pc_compat_rhel630(QEMUMachineInitArgs *args)
|
|
|
9ae3a8 |
enable_compat_apic_id_mode();
|
|
|
9ae3a8 |
x86_cpu_compat_set_features("SandyBridge", FEAT_1_ECX,
|
|
|
9ae3a8 |
0, CPUID_EXT_TSC_DEADLINE_TIMER);
|
|
|
9ae3a8 |
+ x86_cpu_compat_set_features("SandyBridge-IBRS", FEAT_1_ECX,
|
|
|
9ae3a8 |
+ 0, CPUID_EXT_TSC_DEADLINE_TIMER);
|
|
|
9ae3a8 |
}
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
static void pc_init_rhel630(QEMUMachineInitArgs *args)
|
|
|
9ae3a8 |
diff --git a/hw/i386/pc_q35.c b/hw/i386/pc_q35.c
|
|
|
9ae3a8 |
index 850a25a..e6043df 100644
|
|
|
9ae3a8 |
--- a/hw/i386/pc_q35.c
|
|
|
9ae3a8 |
+++ b/hw/i386/pc_q35.c
|
|
|
9ae3a8 |
@@ -228,6 +228,7 @@ static void pc_q35_init_1_4(QEMUMachineInitArgs *args)
|
|
|
9ae3a8 |
{
|
|
|
9ae3a8 |
x86_cpu_compat_set_features("n270", FEAT_1_ECX, 0, CPUID_EXT_MOVBE);
|
|
|
9ae3a8 |
x86_cpu_compat_set_features("Westmere", FEAT_1_ECX, 0, CPUID_EXT_PCLMULQDQ);
|
|
|
9ae3a8 |
+ x86_cpu_compat_set_features("Westmere-IBRS", FEAT_1_ECX, 0, CPUID_EXT_PCLMULQDQ);
|
|
|
9ae3a8 |
pc_q35_init_1_5(args);
|
|
|
9ae3a8 |
}
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
diff --git a/target-i386/cpu.c b/target-i386/cpu.c
|
|
|
9ae3a8 |
index 335689b..08b43f5 100644
|
|
|
9ae3a8 |
--- a/target-i386/cpu.c
|
|
|
9ae3a8 |
+++ b/target-i386/cpu.c
|
|
|
9ae3a8 |
@@ -884,6 +884,31 @@ static x86_def_t builtin_x86_defs[] = {
|
|
|
9ae3a8 |
.model_id = "Intel Core i7 9xx (Nehalem Class Core i7)",
|
|
|
9ae3a8 |
},
|
|
|
9ae3a8 |
{
|
|
|
9ae3a8 |
+ .name = "Nehalem-IBRS",
|
|
|
9ae3a8 |
+ .level = 11,
|
|
|
9ae3a8 |
+ .vendor = CPUID_VENDOR_INTEL,
|
|
|
9ae3a8 |
+ .family = 6,
|
|
|
9ae3a8 |
+ .model = 26,
|
|
|
9ae3a8 |
+ .stepping = 3,
|
|
|
9ae3a8 |
+ .features[FEAT_1_EDX] =
|
|
|
9ae3a8 |
+ CPUID_SSE2 | CPUID_SSE | CPUID_FXSR | CPUID_MMX |
|
|
|
9ae3a8 |
+ CPUID_CLFLUSH | CPUID_PSE36 | CPUID_PAT | CPUID_CMOV | CPUID_MCA |
|
|
|
9ae3a8 |
+ CPUID_PGE | CPUID_MTRR | CPUID_SEP | CPUID_APIC | CPUID_CX8 |
|
|
|
9ae3a8 |
+ CPUID_MCE | CPUID_PAE | CPUID_MSR | CPUID_TSC | CPUID_PSE |
|
|
|
9ae3a8 |
+ CPUID_DE | CPUID_FP87,
|
|
|
9ae3a8 |
+ .features[FEAT_1_ECX] =
|
|
|
9ae3a8 |
+ CPUID_EXT_POPCNT | CPUID_EXT_SSE42 | CPUID_EXT_SSE41 |
|
|
|
9ae3a8 |
+ CPUID_EXT_CX16 | CPUID_EXT_SSSE3 | CPUID_EXT_SSE3,
|
|
|
9ae3a8 |
+ .features[FEAT_7_0_EDX] =
|
|
|
9ae3a8 |
+ CPUID_7_0_EDX_SPEC_CTRL,
|
|
|
9ae3a8 |
+ .features[FEAT_8000_0001_EDX] =
|
|
|
9ae3a8 |
+ CPUID_EXT2_LM | CPUID_EXT2_SYSCALL | CPUID_EXT2_NX,
|
|
|
9ae3a8 |
+ .features[FEAT_8000_0001_ECX] =
|
|
|
9ae3a8 |
+ CPUID_EXT3_LAHF_LM,
|
|
|
9ae3a8 |
+ .xlevel = 0x80000008,
|
|
|
9ae3a8 |
+ .model_id = "Intel Core i7 9xx (Nehalem Core i7, IBRS update)",
|
|
|
9ae3a8 |
+ },
|
|
|
9ae3a8 |
+ {
|
|
|
9ae3a8 |
.name = "Westmere",
|
|
|
9ae3a8 |
.level = 11,
|
|
|
9ae3a8 |
.vendor = CPUID_VENDOR_INTEL,
|
|
|
9ae3a8 |
@@ -908,6 +933,32 @@ static x86_def_t builtin_x86_defs[] = {
|
|
|
9ae3a8 |
.model_id = "Westmere E56xx/L56xx/X56xx (Nehalem-C)",
|
|
|
9ae3a8 |
},
|
|
|
9ae3a8 |
{
|
|
|
9ae3a8 |
+ .name = "Westmere-IBRS",
|
|
|
9ae3a8 |
+ .level = 11,
|
|
|
9ae3a8 |
+ .vendor = CPUID_VENDOR_INTEL,
|
|
|
9ae3a8 |
+ .family = 6,
|
|
|
9ae3a8 |
+ .model = 44,
|
|
|
9ae3a8 |
+ .stepping = 1,
|
|
|
9ae3a8 |
+ .features[FEAT_1_EDX] =
|
|
|
9ae3a8 |
+ CPUID_SSE2 | CPUID_SSE | CPUID_FXSR | CPUID_MMX |
|
|
|
9ae3a8 |
+ CPUID_CLFLUSH | CPUID_PSE36 | CPUID_PAT | CPUID_CMOV | CPUID_MCA |
|
|
|
9ae3a8 |
+ CPUID_PGE | CPUID_MTRR | CPUID_SEP | CPUID_APIC | CPUID_CX8 |
|
|
|
9ae3a8 |
+ CPUID_MCE | CPUID_PAE | CPUID_MSR | CPUID_TSC | CPUID_PSE |
|
|
|
9ae3a8 |
+ CPUID_DE | CPUID_FP87,
|
|
|
9ae3a8 |
+ .features[FEAT_1_ECX] =
|
|
|
9ae3a8 |
+ CPUID_EXT_AES | CPUID_EXT_POPCNT | CPUID_EXT_SSE42 |
|
|
|
9ae3a8 |
+ CPUID_EXT_SSE41 | CPUID_EXT_CX16 | CPUID_EXT_SSSE3 |
|
|
|
9ae3a8 |
+ CPUID_EXT_PCLMULQDQ | CPUID_EXT_SSE3,
|
|
|
9ae3a8 |
+ .features[FEAT_8000_0001_EDX] =
|
|
|
9ae3a8 |
+ CPUID_EXT2_LM | CPUID_EXT2_SYSCALL | CPUID_EXT2_NX,
|
|
|
9ae3a8 |
+ .features[FEAT_8000_0001_ECX] =
|
|
|
9ae3a8 |
+ CPUID_EXT3_LAHF_LM,
|
|
|
9ae3a8 |
+ .features[FEAT_7_0_EDX] =
|
|
|
9ae3a8 |
+ CPUID_7_0_EDX_SPEC_CTRL,
|
|
|
9ae3a8 |
+ .xlevel = 0x80000008,
|
|
|
9ae3a8 |
+ .model_id = "Westmere E56xx/L56xx/X56xx (IBRS update)",
|
|
|
9ae3a8 |
+ },
|
|
|
9ae3a8 |
+ {
|
|
|
9ae3a8 |
.name = "SandyBridge",
|
|
|
9ae3a8 |
.level = 0xd,
|
|
|
9ae3a8 |
.vendor = CPUID_VENDOR_INTEL,
|
|
|
9ae3a8 |
@@ -937,6 +988,37 @@ static x86_def_t builtin_x86_defs[] = {
|
|
|
9ae3a8 |
.model_id = "Intel Xeon E312xx (Sandy Bridge)",
|
|
|
9ae3a8 |
},
|
|
|
9ae3a8 |
{
|
|
|
9ae3a8 |
+ .name = "SandyBridge-IBRS",
|
|
|
9ae3a8 |
+ .level = 0xd,
|
|
|
9ae3a8 |
+ .vendor = CPUID_VENDOR_INTEL,
|
|
|
9ae3a8 |
+ .family = 6,
|
|
|
9ae3a8 |
+ .model = 42,
|
|
|
9ae3a8 |
+ .stepping = 1,
|
|
|
9ae3a8 |
+ .features[FEAT_1_EDX] =
|
|
|
9ae3a8 |
+ CPUID_SSE2 | CPUID_SSE | CPUID_FXSR | CPUID_MMX |
|
|
|
9ae3a8 |
+ CPUID_CLFLUSH | CPUID_PSE36 | CPUID_PAT | CPUID_CMOV | CPUID_MCA |
|
|
|
9ae3a8 |
+ CPUID_PGE | CPUID_MTRR | CPUID_SEP | CPUID_APIC | CPUID_CX8 |
|
|
|
9ae3a8 |
+ CPUID_MCE | CPUID_PAE | CPUID_MSR | CPUID_TSC | CPUID_PSE |
|
|
|
9ae3a8 |
+ CPUID_DE | CPUID_FP87,
|
|
|
9ae3a8 |
+ .features[FEAT_1_ECX] =
|
|
|
9ae3a8 |
+ CPUID_EXT_AVX | CPUID_EXT_XSAVE | CPUID_EXT_AES |
|
|
|
9ae3a8 |
+ CPUID_EXT_TSC_DEADLINE_TIMER | CPUID_EXT_POPCNT |
|
|
|
9ae3a8 |
+ CPUID_EXT_X2APIC | CPUID_EXT_SSE42 | CPUID_EXT_SSE41 |
|
|
|
9ae3a8 |
+ CPUID_EXT_CX16 | CPUID_EXT_SSSE3 | CPUID_EXT_PCLMULQDQ |
|
|
|
9ae3a8 |
+ CPUID_EXT_SSE3,
|
|
|
9ae3a8 |
+ .features[FEAT_8000_0001_EDX] =
|
|
|
9ae3a8 |
+ CPUID_EXT2_LM | CPUID_EXT2_RDTSCP | CPUID_EXT2_NX |
|
|
|
9ae3a8 |
+ CPUID_EXT2_SYSCALL,
|
|
|
9ae3a8 |
+ .features[FEAT_8000_0001_ECX] =
|
|
|
9ae3a8 |
+ CPUID_EXT3_LAHF_LM,
|
|
|
9ae3a8 |
+ .features[FEAT_7_0_EDX] =
|
|
|
9ae3a8 |
+ CPUID_7_0_EDX_SPEC_CTRL,
|
|
|
9ae3a8 |
+ .features[FEAT_XSAVE] =
|
|
|
9ae3a8 |
+ CPUID_XSAVE_XSAVEOPT,
|
|
|
9ae3a8 |
+ .xlevel = 0x80000008,
|
|
|
9ae3a8 |
+ .model_id = "Intel Xeon E312xx (Sandy Bridge, IBRS update)",
|
|
|
9ae3a8 |
+ },
|
|
|
9ae3a8 |
+ {
|
|
|
9ae3a8 |
.name = "IvyBridge",
|
|
|
9ae3a8 |
.level = 0xd,
|
|
|
9ae3a8 |
.vendor = CPUID_VENDOR_INTEL,
|
|
|
9ae3a8 |
@@ -969,6 +1051,40 @@ static x86_def_t builtin_x86_defs[] = {
|
|
|
9ae3a8 |
.model_id = "Intel Xeon E3-12xx v2 (Ivy Bridge)",
|
|
|
9ae3a8 |
},
|
|
|
9ae3a8 |
{
|
|
|
9ae3a8 |
+ .name = "IvyBridge-IBRS",
|
|
|
9ae3a8 |
+ .level = 0xd,
|
|
|
9ae3a8 |
+ .vendor = CPUID_VENDOR_INTEL,
|
|
|
9ae3a8 |
+ .family = 6,
|
|
|
9ae3a8 |
+ .model = 58,
|
|
|
9ae3a8 |
+ .stepping = 9,
|
|
|
9ae3a8 |
+ .features[FEAT_1_EDX] =
|
|
|
9ae3a8 |
+ CPUID_VME | CPUID_SSE2 | CPUID_SSE | CPUID_FXSR | CPUID_MMX |
|
|
|
9ae3a8 |
+ CPUID_CLFLUSH | CPUID_PSE36 | CPUID_PAT | CPUID_CMOV | CPUID_MCA |
|
|
|
9ae3a8 |
+ CPUID_PGE | CPUID_MTRR | CPUID_SEP | CPUID_APIC | CPUID_CX8 |
|
|
|
9ae3a8 |
+ CPUID_MCE | CPUID_PAE | CPUID_MSR | CPUID_TSC | CPUID_PSE |
|
|
|
9ae3a8 |
+ CPUID_DE | CPUID_FP87,
|
|
|
9ae3a8 |
+ .features[FEAT_1_ECX] =
|
|
|
9ae3a8 |
+ CPUID_EXT_AVX | CPUID_EXT_XSAVE | CPUID_EXT_AES |
|
|
|
9ae3a8 |
+ CPUID_EXT_TSC_DEADLINE_TIMER | CPUID_EXT_POPCNT |
|
|
|
9ae3a8 |
+ CPUID_EXT_X2APIC | CPUID_EXT_SSE42 | CPUID_EXT_SSE41 |
|
|
|
9ae3a8 |
+ CPUID_EXT_CX16 | CPUID_EXT_SSSE3 | CPUID_EXT_PCLMULQDQ |
|
|
|
9ae3a8 |
+ CPUID_EXT_SSE3 | CPUID_EXT_F16C | CPUID_EXT_RDRAND,
|
|
|
9ae3a8 |
+ .features[FEAT_7_0_EBX] =
|
|
|
9ae3a8 |
+ CPUID_7_0_EBX_FSGSBASE | CPUID_7_0_EBX_SMEP |
|
|
|
9ae3a8 |
+ CPUID_7_0_EBX_ERMS,
|
|
|
9ae3a8 |
+ .features[FEAT_8000_0001_EDX] =
|
|
|
9ae3a8 |
+ CPUID_EXT2_LM | CPUID_EXT2_RDTSCP | CPUID_EXT2_NX |
|
|
|
9ae3a8 |
+ CPUID_EXT2_SYSCALL,
|
|
|
9ae3a8 |
+ .features[FEAT_8000_0001_ECX] =
|
|
|
9ae3a8 |
+ CPUID_EXT3_LAHF_LM,
|
|
|
9ae3a8 |
+ .features[FEAT_7_0_EDX] =
|
|
|
9ae3a8 |
+ CPUID_7_0_EDX_SPEC_CTRL,
|
|
|
9ae3a8 |
+ .features[FEAT_XSAVE] =
|
|
|
9ae3a8 |
+ CPUID_XSAVE_XSAVEOPT,
|
|
|
9ae3a8 |
+ .xlevel = 0x80000008,
|
|
|
9ae3a8 |
+ .model_id = "Intel Xeon E3-12xx v2 (Ivy Bridge, IBRS)",
|
|
|
9ae3a8 |
+ },
|
|
|
9ae3a8 |
+ {
|
|
|
9ae3a8 |
.name = "Haswell",
|
|
|
9ae3a8 |
.level = 0xd,
|
|
|
9ae3a8 |
.vendor = CPUID_VENDOR_INTEL,
|
|
|
9ae3a8 |
@@ -1004,6 +1120,43 @@ static x86_def_t builtin_x86_defs[] = {
|
|
|
9ae3a8 |
.model_id = "Intel Core Processor (Haswell)",
|
|
|
9ae3a8 |
},
|
|
|
9ae3a8 |
{
|
|
|
9ae3a8 |
+ .name = "Haswell-IBRS",
|
|
|
9ae3a8 |
+ .level = 0xd,
|
|
|
9ae3a8 |
+ .vendor = CPUID_VENDOR_INTEL,
|
|
|
9ae3a8 |
+ .family = 6,
|
|
|
9ae3a8 |
+ .model = 60,
|
|
|
9ae3a8 |
+ .stepping = 4,
|
|
|
9ae3a8 |
+ .features[FEAT_1_EDX] =
|
|
|
9ae3a8 |
+ CPUID_SSE2 | CPUID_SSE | CPUID_FXSR | CPUID_MMX |
|
|
|
9ae3a8 |
+ CPUID_CLFLUSH | CPUID_PSE36 | CPUID_PAT | CPUID_CMOV | CPUID_MCA |
|
|
|
9ae3a8 |
+ CPUID_PGE | CPUID_MTRR | CPUID_SEP | CPUID_APIC | CPUID_CX8 |
|
|
|
9ae3a8 |
+ CPUID_MCE | CPUID_PAE | CPUID_MSR | CPUID_TSC | CPUID_PSE |
|
|
|
9ae3a8 |
+ CPUID_DE | CPUID_FP87,
|
|
|
9ae3a8 |
+ .features[FEAT_1_ECX] =
|
|
|
9ae3a8 |
+ CPUID_EXT_AVX | CPUID_EXT_XSAVE | CPUID_EXT_AES |
|
|
|
9ae3a8 |
+ CPUID_EXT_POPCNT | CPUID_EXT_X2APIC | CPUID_EXT_SSE42 |
|
|
|
9ae3a8 |
+ CPUID_EXT_SSE41 | CPUID_EXT_CX16 | CPUID_EXT_SSSE3 |
|
|
|
9ae3a8 |
+ CPUID_EXT_PCLMULQDQ | CPUID_EXT_SSE3 |
|
|
|
9ae3a8 |
+ CPUID_EXT_TSC_DEADLINE_TIMER | CPUID_EXT_FMA | CPUID_EXT_MOVBE |
|
|
|
9ae3a8 |
+ CPUID_EXT_PCID,
|
|
|
9ae3a8 |
+ .features[FEAT_8000_0001_EDX] =
|
|
|
9ae3a8 |
+ CPUID_EXT2_LM | CPUID_EXT2_RDTSCP | CPUID_EXT2_NX |
|
|
|
9ae3a8 |
+ CPUID_EXT2_SYSCALL,
|
|
|
9ae3a8 |
+ .features[FEAT_8000_0001_ECX] =
|
|
|
9ae3a8 |
+ CPUID_EXT3_LAHF_LM,
|
|
|
9ae3a8 |
+ .features[FEAT_7_0_EDX] =
|
|
|
9ae3a8 |
+ CPUID_7_0_EDX_SPEC_CTRL,
|
|
|
9ae3a8 |
+ .features[FEAT_7_0_EBX] =
|
|
|
9ae3a8 |
+ CPUID_7_0_EBX_FSGSBASE | CPUID_7_0_EBX_BMI1 |
|
|
|
9ae3a8 |
+ CPUID_7_0_EBX_HLE | CPUID_7_0_EBX_AVX2 | CPUID_7_0_EBX_SMEP |
|
|
|
9ae3a8 |
+ CPUID_7_0_EBX_BMI2 | CPUID_7_0_EBX_ERMS | CPUID_7_0_EBX_INVPCID |
|
|
|
9ae3a8 |
+ CPUID_7_0_EBX_RTM,
|
|
|
9ae3a8 |
+ .features[FEAT_XSAVE] =
|
|
|
9ae3a8 |
+ CPUID_XSAVE_XSAVEOPT,
|
|
|
9ae3a8 |
+ .xlevel = 0x80000008,
|
|
|
9ae3a8 |
+ .model_id = "Intel Core Processor (Haswell, IBRS)",
|
|
|
9ae3a8 |
+ },
|
|
|
9ae3a8 |
+ {
|
|
|
9ae3a8 |
.name = "Broadwell",
|
|
|
9ae3a8 |
.level = 0xd,
|
|
|
9ae3a8 |
.vendor = CPUID_VENDOR_INTEL,
|
|
|
9ae3a8 |
@@ -1040,6 +1193,44 @@ static x86_def_t builtin_x86_defs[] = {
|
|
|
9ae3a8 |
.model_id = "Intel Core Processor (Broadwell)",
|
|
|
9ae3a8 |
},
|
|
|
9ae3a8 |
{
|
|
|
9ae3a8 |
+ .name = "Broadwell-IBRS",
|
|
|
9ae3a8 |
+ .level = 0xd,
|
|
|
9ae3a8 |
+ .vendor = CPUID_VENDOR_INTEL,
|
|
|
9ae3a8 |
+ .family = 6,
|
|
|
9ae3a8 |
+ .model = 61,
|
|
|
9ae3a8 |
+ .stepping = 2,
|
|
|
9ae3a8 |
+ .features[FEAT_1_EDX] =
|
|
|
9ae3a8 |
+ CPUID_SSE2 | CPUID_SSE | CPUID_FXSR | CPUID_MMX |
|
|
|
9ae3a8 |
+ CPUID_CLFLUSH | CPUID_PSE36 | CPUID_PAT | CPUID_CMOV | CPUID_MCA |
|
|
|
9ae3a8 |
+ CPUID_PGE | CPUID_MTRR | CPUID_SEP | CPUID_APIC | CPUID_CX8 |
|
|
|
9ae3a8 |
+ CPUID_MCE | CPUID_PAE | CPUID_MSR | CPUID_TSC | CPUID_PSE |
|
|
|
9ae3a8 |
+ CPUID_DE | CPUID_FP87,
|
|
|
9ae3a8 |
+ .features[FEAT_1_ECX] =
|
|
|
9ae3a8 |
+ CPUID_EXT_AVX | CPUID_EXT_XSAVE | CPUID_EXT_AES |
|
|
|
9ae3a8 |
+ CPUID_EXT_POPCNT | CPUID_EXT_X2APIC | CPUID_EXT_SSE42 |
|
|
|
9ae3a8 |
+ CPUID_EXT_SSE41 | CPUID_EXT_CX16 | CPUID_EXT_SSSE3 |
|
|
|
9ae3a8 |
+ CPUID_EXT_PCLMULQDQ | CPUID_EXT_SSE3 |
|
|
|
9ae3a8 |
+ CPUID_EXT_TSC_DEADLINE_TIMER | CPUID_EXT_FMA | CPUID_EXT_MOVBE |
|
|
|
9ae3a8 |
+ CPUID_EXT_PCID,
|
|
|
9ae3a8 |
+ .features[FEAT_8000_0001_EDX] =
|
|
|
9ae3a8 |
+ CPUID_EXT2_LM | CPUID_EXT2_RDTSCP | CPUID_EXT2_NX |
|
|
|
9ae3a8 |
+ CPUID_EXT2_SYSCALL,
|
|
|
9ae3a8 |
+ .features[FEAT_8000_0001_ECX] =
|
|
|
9ae3a8 |
+ CPUID_EXT3_LAHF_LM | CPUID_EXT3_3DNOWPREFETCH,
|
|
|
9ae3a8 |
+ .features[FEAT_7_0_EDX] =
|
|
|
9ae3a8 |
+ CPUID_7_0_EDX_SPEC_CTRL,
|
|
|
9ae3a8 |
+ .features[FEAT_7_0_EBX] =
|
|
|
9ae3a8 |
+ CPUID_7_0_EBX_FSGSBASE | CPUID_7_0_EBX_BMI1 |
|
|
|
9ae3a8 |
+ CPUID_7_0_EBX_HLE | CPUID_7_0_EBX_AVX2 | CPUID_7_0_EBX_SMEP |
|
|
|
9ae3a8 |
+ CPUID_7_0_EBX_BMI2 | CPUID_7_0_EBX_ERMS | CPUID_7_0_EBX_INVPCID |
|
|
|
9ae3a8 |
+ CPUID_7_0_EBX_RTM | CPUID_7_0_EBX_RDSEED | CPUID_7_0_EBX_ADX |
|
|
|
9ae3a8 |
+ CPUID_7_0_EBX_SMAP,
|
|
|
9ae3a8 |
+ .features[FEAT_XSAVE] =
|
|
|
9ae3a8 |
+ CPUID_XSAVE_XSAVEOPT,
|
|
|
9ae3a8 |
+ .xlevel = 0x80000008,
|
|
|
9ae3a8 |
+ .model_id = "Intel Core Processor (Broadwell, IBRS)",
|
|
|
9ae3a8 |
+ },
|
|
|
9ae3a8 |
+ {
|
|
|
9ae3a8 |
.name = "Skylake-Client",
|
|
|
9ae3a8 |
.level = 0xd,
|
|
|
9ae3a8 |
.vendor = CPUID_VENDOR_INTEL,
|
|
|
9ae3a8 |
@@ -1083,6 +1274,51 @@ static x86_def_t builtin_x86_defs[] = {
|
|
|
9ae3a8 |
.model_id = "Intel Core Processor (Skylake)",
|
|
|
9ae3a8 |
},
|
|
|
9ae3a8 |
{
|
|
|
9ae3a8 |
+ .name = "Skylake-Client-IBRS",
|
|
|
9ae3a8 |
+ .level = 0xd,
|
|
|
9ae3a8 |
+ .vendor = CPUID_VENDOR_INTEL,
|
|
|
9ae3a8 |
+ .family = 6,
|
|
|
9ae3a8 |
+ .model = 94,
|
|
|
9ae3a8 |
+ .stepping = 3,
|
|
|
9ae3a8 |
+ .features[FEAT_1_EDX] =
|
|
|
9ae3a8 |
+ CPUID_VME | CPUID_SSE2 | CPUID_SSE | CPUID_FXSR | CPUID_MMX |
|
|
|
9ae3a8 |
+ CPUID_CLFLUSH | CPUID_PSE36 | CPUID_PAT | CPUID_CMOV | CPUID_MCA |
|
|
|
9ae3a8 |
+ CPUID_PGE | CPUID_MTRR | CPUID_SEP | CPUID_APIC | CPUID_CX8 |
|
|
|
9ae3a8 |
+ CPUID_MCE | CPUID_PAE | CPUID_MSR | CPUID_TSC | CPUID_PSE |
|
|
|
9ae3a8 |
+ CPUID_DE | CPUID_FP87,
|
|
|
9ae3a8 |
+ .features[FEAT_1_ECX] =
|
|
|
9ae3a8 |
+ CPUID_EXT_AVX | CPUID_EXT_XSAVE | CPUID_EXT_AES |
|
|
|
9ae3a8 |
+ CPUID_EXT_POPCNT | CPUID_EXT_X2APIC | CPUID_EXT_SSE42 |
|
|
|
9ae3a8 |
+ CPUID_EXT_SSE41 | CPUID_EXT_CX16 | CPUID_EXT_SSSE3 |
|
|
|
9ae3a8 |
+ CPUID_EXT_PCLMULQDQ | CPUID_EXT_SSE3 |
|
|
|
9ae3a8 |
+ CPUID_EXT_TSC_DEADLINE_TIMER | CPUID_EXT_FMA | CPUID_EXT_MOVBE |
|
|
|
9ae3a8 |
+ CPUID_EXT_PCID | CPUID_EXT_F16C | CPUID_EXT_RDRAND,
|
|
|
9ae3a8 |
+ .features[FEAT_8000_0001_EDX] =
|
|
|
9ae3a8 |
+ CPUID_EXT2_LM | CPUID_EXT2_RDTSCP | CPUID_EXT2_NX |
|
|
|
9ae3a8 |
+ CPUID_EXT2_SYSCALL,
|
|
|
9ae3a8 |
+ .features[FEAT_8000_0001_ECX] =
|
|
|
9ae3a8 |
+ CPUID_EXT3_ABM | CPUID_EXT3_LAHF_LM | CPUID_EXT3_3DNOWPREFETCH,
|
|
|
9ae3a8 |
+ .features[FEAT_7_0_EDX] =
|
|
|
9ae3a8 |
+ CPUID_7_0_EDX_SPEC_CTRL,
|
|
|
9ae3a8 |
+ .features[FEAT_7_0_EBX] =
|
|
|
9ae3a8 |
+ CPUID_7_0_EBX_FSGSBASE | CPUID_7_0_EBX_BMI1 |
|
|
|
9ae3a8 |
+ CPUID_7_0_EBX_HLE | CPUID_7_0_EBX_AVX2 | CPUID_7_0_EBX_SMEP |
|
|
|
9ae3a8 |
+ CPUID_7_0_EBX_BMI2 | CPUID_7_0_EBX_ERMS | CPUID_7_0_EBX_INVPCID |
|
|
|
9ae3a8 |
+ CPUID_7_0_EBX_RTM | CPUID_7_0_EBX_RDSEED | CPUID_7_0_EBX_ADX |
|
|
|
9ae3a8 |
+ CPUID_7_0_EBX_SMAP | CPUID_7_0_EBX_MPX,
|
|
|
9ae3a8 |
+ /* Missing: XSAVES (not supported by some Linux versions,
|
|
|
9ae3a8 |
+ * including v4.1 to v4.12).
|
|
|
9ae3a8 |
+ * KVM doesn't yet expose any XSAVES state save component,
|
|
|
9ae3a8 |
+ * and the only one defined in Skylake (processor tracing)
|
|
|
9ae3a8 |
+ * probably will block migration anyway.
|
|
|
9ae3a8 |
+ */
|
|
|
9ae3a8 |
+ .features[FEAT_XSAVE] =
|
|
|
9ae3a8 |
+ CPUID_XSAVE_XSAVEOPT | CPUID_XSAVE_XSAVEC |
|
|
|
9ae3a8 |
+ CPUID_XSAVE_XGETBV1,
|
|
|
9ae3a8 |
+ .xlevel = 0x80000008,
|
|
|
9ae3a8 |
+ .model_id = "Intel Core Processor (Skylake, IBRS)",
|
|
|
9ae3a8 |
+ },
|
|
|
9ae3a8 |
+ {
|
|
|
9ae3a8 |
.name = "Skylake-Server",
|
|
|
9ae3a8 |
.level = 0xd,
|
|
|
9ae3a8 |
.vendor = CPUID_VENDOR_INTEL,
|
|
|
9ae3a8 |
@@ -1133,6 +1369,54 @@ static x86_def_t builtin_x86_defs[] = {
|
|
|
9ae3a8 |
.model_id = "Intel Xeon Processor (Skylake)",
|
|
|
9ae3a8 |
},
|
|
|
9ae3a8 |
{
|
|
|
9ae3a8 |
+ .name = "Skylake-Server-IBRS",
|
|
|
9ae3a8 |
+ .level = 0xd,
|
|
|
9ae3a8 |
+ .vendor = CPUID_VENDOR_INTEL,
|
|
|
9ae3a8 |
+ .family = 6,
|
|
|
9ae3a8 |
+ .model = 85,
|
|
|
9ae3a8 |
+ .stepping = 4,
|
|
|
9ae3a8 |
+ .features[FEAT_1_EDX] =
|
|
|
9ae3a8 |
+ CPUID_VME | CPUID_SSE2 | CPUID_SSE | CPUID_FXSR | CPUID_MMX |
|
|
|
9ae3a8 |
+ CPUID_CLFLUSH | CPUID_PSE36 | CPUID_PAT | CPUID_CMOV | CPUID_MCA |
|
|
|
9ae3a8 |
+ CPUID_PGE | CPUID_MTRR | CPUID_SEP | CPUID_APIC | CPUID_CX8 |
|
|
|
9ae3a8 |
+ CPUID_MCE | CPUID_PAE | CPUID_MSR | CPUID_TSC | CPUID_PSE |
|
|
|
9ae3a8 |
+ CPUID_DE | CPUID_FP87,
|
|
|
9ae3a8 |
+ .features[FEAT_1_ECX] =
|
|
|
9ae3a8 |
+ CPUID_EXT_AVX | CPUID_EXT_XSAVE | CPUID_EXT_AES |
|
|
|
9ae3a8 |
+ CPUID_EXT_POPCNT | CPUID_EXT_X2APIC | CPUID_EXT_SSE42 |
|
|
|
9ae3a8 |
+ CPUID_EXT_SSE41 | CPUID_EXT_CX16 | CPUID_EXT_SSSE3 |
|
|
|
9ae3a8 |
+ CPUID_EXT_PCLMULQDQ | CPUID_EXT_SSE3 |
|
|
|
9ae3a8 |
+ CPUID_EXT_TSC_DEADLINE_TIMER | CPUID_EXT_FMA | CPUID_EXT_MOVBE |
|
|
|
9ae3a8 |
+ CPUID_EXT_PCID | CPUID_EXT_F16C | CPUID_EXT_RDRAND,
|
|
|
9ae3a8 |
+ .features[FEAT_8000_0001_EDX] =
|
|
|
9ae3a8 |
+ CPUID_EXT2_LM | CPUID_EXT2_PDPE1GB | CPUID_EXT2_RDTSCP |
|
|
|
9ae3a8 |
+ CPUID_EXT2_NX | CPUID_EXT2_SYSCALL,
|
|
|
9ae3a8 |
+ .features[FEAT_8000_0001_ECX] =
|
|
|
9ae3a8 |
+ CPUID_EXT3_ABM | CPUID_EXT3_LAHF_LM | CPUID_EXT3_3DNOWPREFETCH,
|
|
|
9ae3a8 |
+ .features[FEAT_7_0_EDX] =
|
|
|
9ae3a8 |
+ CPUID_7_0_EDX_SPEC_CTRL,
|
|
|
9ae3a8 |
+ .features[FEAT_7_0_EBX] =
|
|
|
9ae3a8 |
+ CPUID_7_0_EBX_FSGSBASE | CPUID_7_0_EBX_BMI1 |
|
|
|
9ae3a8 |
+ CPUID_7_0_EBX_HLE | CPUID_7_0_EBX_AVX2 | CPUID_7_0_EBX_SMEP |
|
|
|
9ae3a8 |
+ CPUID_7_0_EBX_BMI2 | CPUID_7_0_EBX_ERMS | CPUID_7_0_EBX_INVPCID |
|
|
|
9ae3a8 |
+ CPUID_7_0_EBX_RTM | CPUID_7_0_EBX_RDSEED | CPUID_7_0_EBX_ADX |
|
|
|
9ae3a8 |
+ CPUID_7_0_EBX_SMAP | CPUID_7_0_EBX_MPX | CPUID_7_0_EBX_CLWB |
|
|
|
9ae3a8 |
+ CPUID_7_0_EBX_AVX512F | CPUID_7_0_EBX_AVX512DQ |
|
|
|
9ae3a8 |
+ CPUID_7_0_EBX_AVX512BW | CPUID_7_0_EBX_AVX512CD |
|
|
|
9ae3a8 |
+ CPUID_7_0_EBX_AVX512VL,
|
|
|
9ae3a8 |
+ /* Missing: XSAVES (not supported by some Linux versions,
|
|
|
9ae3a8 |
+ * including v4.1 to v4.12).
|
|
|
9ae3a8 |
+ * KVM doesn't yet expose any XSAVES state save component,
|
|
|
9ae3a8 |
+ * and the only one defined in Skylake (processor tracing)
|
|
|
9ae3a8 |
+ * probably will block migration anyway.
|
|
|
9ae3a8 |
+ */
|
|
|
9ae3a8 |
+ .features[FEAT_XSAVE] =
|
|
|
9ae3a8 |
+ CPUID_XSAVE_XSAVEOPT | CPUID_XSAVE_XSAVEC |
|
|
|
9ae3a8 |
+ CPUID_XSAVE_XGETBV1,
|
|
|
9ae3a8 |
+ .xlevel = 0x80000008,
|
|
|
9ae3a8 |
+ .model_id = "Intel Xeon Processor (Skylake, IBRS)",
|
|
|
9ae3a8 |
+ },
|
|
|
9ae3a8 |
+ {
|
|
|
9ae3a8 |
.name = "Opteron_G1",
|
|
|
9ae3a8 |
.level = 5,
|
|
|
9ae3a8 |
.vendor = CPUID_VENDOR_AMD,
|
|
|
9ae3a8 |
@@ -1332,6 +1616,50 @@ static x86_def_t builtin_x86_defs[] = {
|
|
|
9ae3a8 |
.xlevel = 0x8000000A,
|
|
|
9ae3a8 |
.model_id = "AMD EPYC Processor",
|
|
|
9ae3a8 |
},
|
|
|
9ae3a8 |
+ {
|
|
|
9ae3a8 |
+ .name = "EPYC-IBPB",
|
|
|
9ae3a8 |
+ .level = 0xd,
|
|
|
9ae3a8 |
+ .vendor = CPUID_VENDOR_AMD,
|
|
|
9ae3a8 |
+ .family = 23,
|
|
|
9ae3a8 |
+ .model = 1,
|
|
|
9ae3a8 |
+ .stepping = 2,
|
|
|
9ae3a8 |
+ .features[FEAT_1_EDX] =
|
|
|
9ae3a8 |
+ CPUID_SSE2 | CPUID_SSE | CPUID_FXSR | CPUID_MMX | CPUID_CLFLUSH |
|
|
|
9ae3a8 |
+ CPUID_PSE36 | CPUID_PAT | CPUID_CMOV | CPUID_MCA | CPUID_PGE |
|
|
|
9ae3a8 |
+ CPUID_MTRR | CPUID_SEP | CPUID_APIC | CPUID_CX8 | CPUID_MCE |
|
|
|
9ae3a8 |
+ CPUID_PAE | CPUID_MSR | CPUID_TSC | CPUID_PSE | CPUID_DE |
|
|
|
9ae3a8 |
+ CPUID_VME | CPUID_FP87,
|
|
|
9ae3a8 |
+ .features[FEAT_1_ECX] =
|
|
|
9ae3a8 |
+ CPUID_EXT_RDRAND | CPUID_EXT_F16C | CPUID_EXT_AVX |
|
|
|
9ae3a8 |
+ CPUID_EXT_XSAVE | CPUID_EXT_AES | CPUID_EXT_POPCNT |
|
|
|
9ae3a8 |
+ CPUID_EXT_MOVBE | CPUID_EXT_SSE42 | CPUID_EXT_SSE41 |
|
|
|
9ae3a8 |
+ CPUID_EXT_CX16 | CPUID_EXT_FMA | CPUID_EXT_SSSE3 |
|
|
|
9ae3a8 |
+ CPUID_EXT_MONITOR | CPUID_EXT_PCLMULQDQ | CPUID_EXT_SSE3,
|
|
|
9ae3a8 |
+ .features[FEAT_8000_0001_EDX] =
|
|
|
9ae3a8 |
+ CPUID_EXT2_LM | CPUID_EXT2_RDTSCP | CPUID_EXT2_PDPE1GB |
|
|
|
9ae3a8 |
+ CPUID_EXT2_FFXSR | CPUID_EXT2_MMXEXT | CPUID_EXT2_NX |
|
|
|
9ae3a8 |
+ CPUID_EXT2_SYSCALL,
|
|
|
9ae3a8 |
+ .features[FEAT_8000_0001_ECX] =
|
|
|
9ae3a8 |
+ CPUID_EXT3_OSVW | CPUID_EXT3_3DNOWPREFETCH |
|
|
|
9ae3a8 |
+ CPUID_EXT3_MISALIGNSSE | CPUID_EXT3_SSE4A | CPUID_EXT3_ABM |
|
|
|
9ae3a8 |
+ CPUID_EXT3_CR8LEG | CPUID_EXT3_SVM | CPUID_EXT3_LAHF_LM,
|
|
|
9ae3a8 |
+ .features[FEAT_8000_0008_EBX] =
|
|
|
9ae3a8 |
+ CPUID_8000_0008_EBX_IBPB,
|
|
|
9ae3a8 |
+ .features[FEAT_7_0_EBX] =
|
|
|
9ae3a8 |
+ CPUID_7_0_EBX_FSGSBASE | CPUID_7_0_EBX_BMI1 | CPUID_7_0_EBX_AVX2 |
|
|
|
9ae3a8 |
+ CPUID_7_0_EBX_SMEP | CPUID_7_0_EBX_BMI2 | CPUID_7_0_EBX_RDSEED |
|
|
|
9ae3a8 |
+ CPUID_7_0_EBX_ADX | CPUID_7_0_EBX_SMAP | CPUID_7_0_EBX_CLFLUSHOPT |
|
|
|
9ae3a8 |
+ CPUID_7_0_EBX_SHA_NI,
|
|
|
9ae3a8 |
+ /* Missing: XSAVES (not supported by some Linux versions,
|
|
|
9ae3a8 |
+ * including v4.1 to v4.12).
|
|
|
9ae3a8 |
+ * KVM doesn't yet expose any XSAVES state save component.
|
|
|
9ae3a8 |
+ */
|
|
|
9ae3a8 |
+ .features[FEAT_XSAVE] =
|
|
|
9ae3a8 |
+ CPUID_XSAVE_XSAVEOPT | CPUID_XSAVE_XSAVEC |
|
|
|
9ae3a8 |
+ CPUID_XSAVE_XGETBV1,
|
|
|
9ae3a8 |
+ .xlevel = 0x8000000A,
|
|
|
9ae3a8 |
+ .model_id = "AMD EPYC Processor (with IBPB)",
|
|
|
9ae3a8 |
+ },
|
|
|
9ae3a8 |
};
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
/**
|
|
|
9ae3a8 |
diff --git a/target-i386/cpu.h b/target-i386/cpu.h
|
|
|
9ae3a8 |
index 7d815cd..a8a640a 100644
|
|
|
9ae3a8 |
--- a/target-i386/cpu.h
|
|
|
9ae3a8 |
+++ b/target-i386/cpu.h
|
|
|
9ae3a8 |
@@ -589,6 +589,9 @@ typedef uint32_t FeatureWordArray[FEATURE_WORDS];
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
#define CPUID_7_0_EDX_AVX512_4VNNIW (1U << 2) /* AVX512 Neural Network Instructions */
|
|
|
9ae3a8 |
#define CPUID_7_0_EDX_AVX512_4FMAPS (1U << 3) /* AVX512 Multiply Accumulation Single Precision */
|
|
|
9ae3a8 |
+#define CPUID_7_0_EDX_SPEC_CTRL (1U << 26) /* Indirect Branch - Restrict Speculation */
|
|
|
9ae3a8 |
+
|
|
|
9ae3a8 |
+#define CPUID_8000_0008_EBX_IBPB (1U << 12) /* Indirect Branch Prediction Barrier */
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
#define CPUID_7_0_ECX_PKU (1U << 3)
|
|
|
9ae3a8 |
#define CPUID_7_0_ECX_OSPKE (1U << 4)
|
|
|
9ae3a8 |
--
|
|
|
9ae3a8 |
1.8.3.1
|
|
|
9ae3a8 |
|