368 | 368 |
#define FALLBACK(...) \
|
369 | 369 |
else __VA_ARGS__
|
370 | 370 |
|
|
371 |
// This enum combines the topological layers from both Intel & AMD.
|
|
372 |
enum Cotopo {
|
|
373 |
Smt,
|
|
374 |
Core,
|
|
375 |
Cu,
|
|
376 |
Module,
|
|
377 |
Tile,
|
|
378 |
Die,
|
|
379 |
DieGrp,
|
|
380 |
Pkg,
|
|
381 |
NumCotopos,
|
|
382 |
Invalid = NumCotopos,
|
|
383 |
};
|
|
384 |
|
|
385 |
#define V2_TOPO_NUM 7
|
|
386 |
|
|
387 |
static unsigned int v2TopoToCotopo[V2_TOPO_NUM]
|
|
388 |
= { /* invalid (0) => */ Invalid,
|
|
389 |
/* thread (1) => */ Smt,
|
|
390 |
/* core (2) => */ Core,
|
|
391 |
/* module (3) => */ Module,
|
|
392 |
/* tile (4) => */ Tile,
|
|
393 |
/* die (5) => */ Die,
|
|
394 |
/* die group (6) => */ DieGrp };
|
|
395 |
|
371 | 396 |
typedef struct {
|
372 | 397 |
vendor_t vendor;
|
373 | 398 |
boolean saw_4;
|
374 | 399 |
boolean saw_b;
|
375 | 400 |
boolean saw_1f;
|
|
401 |
boolean saw_8000001e;
|
376 | 402 |
unsigned int val_0_eax;
|
377 | 403 |
unsigned int val_1_eax;
|
378 | 404 |
unsigned int val_1_ebx;
|
|
381 | 407 |
unsigned int val_4_eax;
|
382 | 408 |
unsigned int val_b_eax[2];
|
383 | 409 |
unsigned int val_b_ebx[2];
|
|
410 |
unsigned int val_b_edx;
|
384 | 411 |
unsigned int val_1a_0_eax;
|
385 | |
unsigned int val_1f_eax[6];
|
386 | |
unsigned int val_1f_ebx[6];
|
387 | |
unsigned int val_1f_ecx[6];
|
|
412 |
unsigned int val_1f_eax[V2_TOPO_NUM];
|
|
413 |
unsigned int val_1f_ebx[V2_TOPO_NUM];
|
|
414 |
unsigned int val_1f_ecx[V2_TOPO_NUM];
|
|
415 |
unsigned int val_1f_edx;
|
388 | 416 |
unsigned int val_80000001_eax;
|
389 | 417 |
unsigned int val_80000001_ebx;
|
390 | 418 |
unsigned int val_80000001_ecx;
|
391 | 419 |
unsigned int val_80000001_edx;
|
392 | 420 |
unsigned int val_80000008_ecx;
|
|
421 |
unsigned int val_8000001e_eax;
|
393 | 422 |
unsigned int val_8000001e_ebx;
|
394 | 423 |
unsigned int transmeta_proc_rev;
|
395 | 424 |
char brand[48+1];
|
|
400 | 429 |
|
401 | 430 |
struct mp {
|
402 | 431 |
const char* method;
|
403 | |
unsigned int cores;
|
404 | |
unsigned int hyperthreads;
|
|
432 |
unsigned int count[NumCotopos];
|
405 | 433 |
} mp;
|
406 | 434 |
|
407 | 435 |
struct br {
|
|
504 | 532 |
} code_stash_t;
|
505 | 533 |
|
506 | 534 |
#define NIL_STASH { VENDOR_UNKNOWN, \
|
507 | |
FALSE, FALSE, FALSE, \
|
|
535 |
FALSE, FALSE, FALSE, FALSE, \
|
508 | 536 |
0, 0, 0, 0, 0, 0, \
|
509 | 537 |
{ 0, 0 }, \
|
510 | 538 |
{ 0, 0 }, \
|
511 | 539 |
0, \
|
512 | |
{ 0, 0, 0, 0, 0, 0 }, \
|
513 | |
{ 0, 0, 0, 0, 0, 0 }, \
|
514 | |
{ 0, 0, 0, 0, 0, 0 }, \
|
515 | |
0, 0, 0, 0, 0, 0, 0, \
|
|
540 |
0, \
|
|
541 |
{ 0, 0, 0, 0, 0, 0, 0 }, \
|
|
542 |
{ 0, 0, 0, 0, 0, 0, 0 }, \
|
|
543 |
{ 0, 0, 0, 0, 0, 0, 0 }, \
|
|
544 |
0, \
|
|
545 |
0, 0, 0, 0, 0, 0, 0, 0, \
|
516 | 546 |
"", "", "", "", \
|
517 | 547 |
HYPERVISOR_UNKNOWN, \
|
518 | |
{ NULL, -1, -1 }, \
|
|
548 |
{ NULL, { 0, 0, 0, 0, 0, 0, 0, 0 } }, \
|
519 | 549 |
{ FALSE, \
|
520 | 550 |
{ FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, \
|
521 | 551 |
FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, FALSE, \
|
|
1767 | 1797 |
/* Dual-Core Xeon Processor 5100 (Woodcrest B1) pre-production,
|
1768 | 1798 |
distinguished from Core 2 Duo (Conroe B1) */
|
1769 | 1799 |
#define QW (dG && stash->br.generic \
|
1770 | |
&& (stash->mp.cores == 4 \
|
1771 | |
|| (stash->mp.cores == 2 && stash->mp.hyperthreads == 2)))
|
|
1800 |
&& (stash->mp.count[Core] == 4 \
|
|
1801 |
|| (stash->mp.count[Core] == 2 && stash->mp.count[Smt] == 2)))
|
1772 | 1802 |
/* Core Duo (Yonah), distinguished from Core Solo (Yonah) */
|
1773 | |
#define DG (dG && stash->mp.cores == 2)
|
|
1803 |
#define DG (dG && stash->mp.count[Core] == 2)
|
1774 | 1804 |
/* Core 2 Quad, distinguished from Core 2 Duo */
|
1775 | |
#define Qc (dc && stash->mp.cores == 4)
|
|
1805 |
#define Qc (dc && stash->mp.count[Core] == 4)
|
1776 | 1806 |
/* Core 2 Extreme (Conroe B1), distinguished from Core 2 Duo (Conroe B1) */
|
1777 | 1807 |
#define XE (dc && strstr(stash->brand, " E6800") != NULL)
|
1778 | 1808 |
/* Quad-Core Xeon, distinguished from Xeon; and
|
1779 | 1809 |
Xeon Processor 3300, distinguished from Xeon Processor 3100 */
|
1780 | |
#define sQ (sX && stash->mp.cores == 4)
|
|
1810 |
#define sQ (sX && stash->mp.count[Core] == 4)
|
1781 | 1811 |
/* Xeon Processor 7000, distinguished from Xeon */
|
1782 | 1812 |
#define IS_VMX(val_1_ecx) (BIT_EXTRACT_LE((val_1_ecx), 5, 6))
|
1783 | 1813 |
#define s7 (sX && IS_VMX(stash->val_1_ecx))
|
|
1804 | 1834 |
#define Hz (is_intel && HYBRID_CORE_TYPE(stash->val_1a_0_eax) == 0x00)
|
1805 | 1835 |
#define Ha (is_intel && HYBRID_CORE_TYPE(stash->val_1a_0_eax) == 0x20)
|
1806 | 1836 |
#define Hc (is_intel && HYBRID_CORE_TYPE(stash->val_1a_0_eax) == 0x40)
|
|
1837 |
/* Hybrid special cases where "Core" implies a different branding than usual,
|
|
1838 |
such as the Core i3 N-Series */
|
|
1839 |
#define Ia (is_intel && stash->br.core && HYBRID_CORE_TYPE(stash->val_1a_0_eax) == 0x20)
|
|
1840 |
#define Ic (is_intel && stash->br.core && HYBRID_CORE_TYPE(stash->val_1a_0_eax) == 0x40)
|
1807 | 1841 |
|
1808 | 1842 |
/*
|
1809 | 1843 |
** AMD major queries:
|
|
2091 | 2125 |
//
|
2092 | 2126 |
|
2093 | 2127 |
START;
|
2094 | |
F ( 0, 4, *f = "i486"); // *p depends on core
|
2095 | |
FM ( 0, 5, 0, 0, *f = "P5", *p = ".8um");
|
2096 | |
FM ( 0, 5, 0, 1, *f = "P5", *p = ".8um");
|
|
2128 |
F ( 0, 4, *f = "i486"); // *p depends on core
|
|
2129 |
FM ( 0, 5, 0, 0, *f = "P5", *p = ".8um");
|
|
2130 |
FM ( 0, 5, 0, 1, *f = "P5", *p = ".8um");
|
2097 | 2131 |
FM ( 0, 5, 0, 2, *f = "P5");
|
2098 | |
FM ( 0, 5, 0, 3, *f = "P5", *p = ".6um");
|
|
2132 |
FM ( 0, 5, 0, 3, *f = "P5", *p = ".6um");
|
2099 | 2133 |
FM ( 0, 5, 0, 4, *f = "P5 MMX");
|
2100 | 2134 |
FM ( 0, 5, 0, 7, *f = "P5 MMX");
|
2101 | |
FM ( 0, 5, 0, 8, *f = "P5 MMX", *p = ".25um");
|
|
2135 |
FM ( 0, 5, 0, 8, *f = "P5 MMX", *p = ".25um");
|
2102 | 2136 |
FM ( 0, 5, 0, 9, *f = "P5 MMX");
|
2103 | 2137 |
FM ( 0, 6, 0, 0, *f = "P6 Pentium II");
|
2104 | |
FM ( 0, 6, 0, 1, *f = "P6 Pentium II"); // *p depends on core
|
|
2138 |
FM ( 0, 6, 0, 1, *f = "P6 Pentium II"); // *p depends on core
|
2105 | 2139 |
FM ( 0, 6, 0, 2, *f = "P6 Pentium II");
|
2106 | |
FM ( 0, 6, 0, 3, *f = "P6 Pentium II", *p = ".35um");
|
|
2140 |
FM ( 0, 6, 0, 3, *f = "P6 Pentium II", *p = ".35um");
|
2107 | 2141 |
FM ( 0, 6, 0, 4, *f = "P6 Pentium II");
|
2108 | |
FM ( 0, 6, 0, 5, *f = "P6 Pentium II", *p = ".25um");
|
2109 | |
FM ( 0, 6, 0, 6, *f = "P6 Pentium II", *p = "L2 cache");
|
2110 | |
FM ( 0, 6, 0, 7, *f = "P6 Pentium III", *p = ".25um");
|
2111 | |
FM ( 0, 6, 0, 8, *f = "P6 Pentium III", *p = ".18um");
|
2112 | |
FM ( 0, 6, 0, 9, *f = "P6 Pentium M", *p = ".13um");
|
2113 | |
FM ( 0, 6, 0,10, *f = "P6 Pentium III", *p = ".18um");
|
2114 | |
FM ( 0, 6, 0,11, *f = "P6 Pentium III", *p = ".13um");
|
2115 | |
FM ( 0, 6, 0,13, *u = "Dothan", *f = "P6 Pentium M"); // *p depends on core
|
2116 | |
FM ( 0, 6, 0,14, *u = "Yonah", *f = "P6 Pentium M", *p = "65nm");
|
2117 | |
FM ( 0, 6, 0,15, *u = "Merom", *f = "Core", *p = "65nm");
|
2118 | |
FM ( 0, 6, 1, 5, *u = "Dothan", *f = "P6 Pentium M", *p = "90nm");
|
2119 | |
FM ( 0, 6, 1, 6, *u = "Merom", *f = "Core", *p = "65nm");
|
2120 | |
FM ( 0, 6, 1, 7, *u = "Penryn", *f = "Core", *p = "45nm");
|
2121 | |
FM ( 0, 6, 1,10, *u = "Nehalem", *f = "Nehalem", *p = "45nm");
|
2122 | |
FM ( 0, 6, 1,12, *u = "Bonnell", *p = "45nm");
|
2123 | |
FM ( 0, 6, 1,13, *u = "Penryn", *f = "Core", *p = "45nm");
|
2124 | |
FM ( 0, 6, 1,14, *u = "Nehalem", *f = "Nehalem", *p = "45nm");
|
2125 | |
FM ( 0, 6, 1,15, *u = "Nehalem", *f = "Nehalem", *p = "45nm");
|
2126 | |
FM ( 0, 6, 2, 5, *u = "Westmere", *f = "shrink of Nehalem", *p = "32nm");
|
2127 | |
FM ( 0, 6, 2, 6, *u = "Bonnell", *p = "45nm");
|
2128 | |
FM ( 0, 6, 2, 7, *u = "Saltwell", *p = "32nm");
|
2129 | |
FM ( 0, 6, 2,10, *u = "Sandy Bridge", *ciu = TRUE, *f = "Sandy Bridge", *p = "32nm");
|
2130 | |
FM ( 0, 6, 2,12, *u = "Westmere", *f = "shrink of Nehalem", *p = "32nm");
|
2131 | |
FM ( 0, 6, 2,13, *u = "Sandy Bridge", *ciu = TRUE, *f = "Sandy Bridge", *p = "32nm");
|
2132 | |
FM ( 0, 6, 2,14, *u = "Nehalem", *f = "Nehalem", *p = "45nm");
|
2133 | |
FM ( 0, 6, 2,15, *u = "Westmere", *f = "shrink of Nehalem", *p = "32nm");
|
2134 | |
FM ( 0, 6, 3, 5, *u = "Saltwell", *p = "14nm");
|
2135 | |
FM ( 0, 6, 3, 6, *u = "Saltwell", *p = "32nm");
|
2136 | |
FM ( 0, 6, 3, 7, *u = "Silvermont", *p = "22nm");
|
2137 | |
FM ( 0, 6, 3,10, *u = "Ivy Bridge", *ciu = TRUE, *f = "shrink of Sandy Bridge", *p = "22nm");
|
2138 | |
FM ( 0, 6, 3,12, *u = "Haswell", *ciu = TRUE, *f = "Haswell", *p = "22nm");
|
2139 | |
FM ( 0, 6, 3,13, *u = "Broadwell", *ciu = TRUE, *f = "shrink of Haswell", *p = "14nm");
|
2140 | |
FM ( 0, 6, 3,14, *u = "Ivy Bridge", *ciu = TRUE, *f = "shrink of Sandy Bridge", *p = "22nm");
|
2141 | |
FM ( 0, 6, 3,15, *u = "Haswell", *ciu = TRUE, *f = "Haswell", *p = "22nm");
|
2142 | |
FM ( 0, 6, 4, 5, *u = "Haswell", *ciu = TRUE, *f = "Haswell", *p = "22nm");
|
2143 | |
FM ( 0, 6, 4, 6, *u = "Haswell", *ciu = TRUE, *f = "Haswell", *p = "22nm");
|
2144 | |
FM ( 0, 6, 4, 7, *u = "Broadwell", *ciu = TRUE, *f = "shrink of Haswell", *p = "14nm");
|
2145 | |
FM ( 0, 6, 4,10, *u = "Silvermont", *p = "22nm"); // no docs, but /proc/cpuinfo seen in wild
|
2146 | |
FM ( 0, 6, 4,12, *u = "Airmont", *p = "14nm");
|
2147 | |
FM ( 0, 6, 4,13, *u = "Silvermont", *p = "22nm");
|
2148 | |
FMS ( 0, 6, 4,14, 8, *u = "Kaby Lake", *f = "optim of Skylake", *p = "14nm+");
|
2149 | |
FM ( 0, 6, 4,14, *u = "Skylake", *ciu = TRUE, *f = "Skylake", *p = "14nm");
|
2150 | |
FM ( 0, 6, 4,15, *u = "Broadwell", *ciu = TRUE, *f = "shrink of Haswell", *p = "14nm");
|
2151 | |
FMQ ( 0, 6, 5, 5, iM, *u = "Jintide Gen1", *ciu = TRUE); // undocumented; only instlatx64 example
|
2152 | |
FMS ( 0, 6, 5, 5, 6, *u = "Cascade Lake", *ciu = TRUE, *f = "optim of Skylake", *p = "14nm++"); // no docs, but example from Greg Stewart
|
2153 | |
FMS ( 0, 6, 5, 5, 7, *u = "Cascade Lake", *ciu = TRUE, *f = "optim of Skylake", *p = "14nm++");
|
2154 | |
FMS ( 0, 6, 5, 5, 10, *u = "Cooper Lake", *ciu = TRUE, *f = "optim of Cascade Lake, optim of Skylake", *p = "14nm++");
|
2155 | |
FM ( 0, 6, 5, 5, *u = "Skylake", *ciu = TRUE, *f = "Skylake", *p = "14nm");
|
2156 | |
FM ( 0, 6, 5, 6, *u = "Broadwell", *ciu = TRUE, *f = "shrink of Haswell", *p = "14nm");
|
2157 | |
FM ( 0, 6, 5, 7, *u = "Knights Landing", *ciu = TRUE, *p = "14nm");
|
2158 | |
FM ( 0, 6, 5,10, *u = "Silvermont", *p = "22nm"); // no spec update; only MSR_CPUID_table* so far
|
2159 | |
FM ( 0, 6, 5,12, *u = "Goldmont", *p = "14nm"); // no spec update for Atom; only MSR_CPUID_table* so far
|
2160 | |
FM ( 0, 6, 5,13, *u = "Silvermont", *p = "22nm"); // no spec update; only MSR_CPUID_table* so far
|
2161 | |
FMS ( 0, 6, 5,14, 8, *u = "Kaby Lake", *f = "optim of Skylake", *p = "14nm+");
|
2162 | |
FM ( 0, 6, 5,14, *u = "Skylake", *ciu = TRUE, *f = "Skylake", *p = "14nm");
|
2163 | |
FM ( 0, 6, 5,15, *u = "Goldmont", *p = "14nm");
|
2164 | |
FM ( 0, 6, 6, 6, *u = "Palm Cove", *f = "Palm Cove", *p = "10nm"); // no spec update; only MSR_CPUID_table* so far
|
2165 | |
FM ( 0, 6, 6, 7, *u = "Palm Cove", *f = "Palm Cove", *p = "10nm"); // DPTF*
|
2166 | |
FM ( 0, 6, 6,10, *u = "Sunny Cove", *f = "Sunny Cove", *p = "10nm+");
|
2167 | |
FM ( 0, 6, 6,12, *u = "Sunny Cove", *f = "Sunny Cove", *p = "10nm+"); // no spec update; only MSR_CPUID_table* so far; DPTF* claims this is Meteor Lake S => Redwood Cove
|
2168 | |
FM ( 0, 6, 6,14, *u = "Airmont", *p = "14nm"); // no spec update; only Intel's "Retpoline: A Branch Target Injection Mitigation"
|
2169 | |
FM ( 0, 6, 7, 5, *u = "Airmont", *p = "14nm"); // no spec update; whispers & rumors
|
2170 | |
FM ( 0, 6, 7,10, *u = "Goldmont Plus", *p = "14nm");
|
2171 | |
FM ( 0, 6, 7,13, *u = "Sunny Cove", *f = "Sunny Cove", *p = "10nm+"); // no spec update; only MSR_CPUID_table* so far
|
2172 | |
FM ( 0, 6, 7,14, *u = "Sunny Cove", *f = "Sunny Cove", *p = "10nm+");
|
2173 | |
FM ( 0, 6, 8, 5, *u = "Knights Mill", *ciu = TRUE, *p = "14nm"); // no spec update; only MSR_CPUID_table* so far
|
2174 | |
FM ( 0, 6, 8, 6, *u = "Tremont", *p = "10nm"); // LX*
|
2175 | |
FMQ ( 0, 6, 8,10, Ha, *u = "Tremont", *p = "10nm"); // no spec update; LX*
|
2176 | |
FMQ ( 0, 6, 8,10, Hc, *u = "Sunny Cove", *p = "10nm"); // no spec update; LX*
|
2177 | |
FM ( 0, 6, 8,12, *u = "Willow Cove", *f = "optim of Sunny Cove", *p = "10nm++"); // no spec update; only MSR_CPUID_table* so far
|
2178 | |
FM ( 0, 6, 8,13, *u = "Willow Cove", *f = "optim of Sunny Cove", *p = "10nm++"); // no spec update; only MSR_CPUID_table* so far
|
2179 | |
FM ( 0, 6, 8,14, *u = "Kaby Lake", *f = "optim of Skylake", *p = "14nm+/14nm++");
|
2180 | |
FM ( 0, 6, 8,15, *u = "Sapphire Rapids", *f = "Sunny Cove", *p = "10nm+"); // LX*
|
2181 | |
FM ( 0, 6, 9, 6, *u = "Tremont", *p = "10nm"); // LX*
|
2182 | |
FMQ ( 0, 6, 9, 7, Ha, *u = "Gracemont", *p = "Intel 7");
|
2183 | |
FMQ ( 0, 6, 9, 7, Hc, *u = "Golden Cove", *p = "Intel 7");
|
2184 | |
FMQ ( 0, 6, 9, 7, Hz, *u = "Golden Cove", *p = "Intel 7");
|
2185 | |
FMQ ( 0, 6, 9,10, Ha, *u = "Gracemont", *p = "Intel 7"); // Coreboot*
|
2186 | |
FMQ ( 0, 6, 9,10, Hc, *u = "Golden Cove", *p = "Intel 7"); // Coreboot*
|
2187 | |
FM ( 0, 6, 9,12, *u = "Tremont", *p = "10nm"); // LX*
|
2188 | |
FM ( 0, 6, 9,13, *u = "Sunny Cove", *f = "Sunny Cove", *p = "10nm+"); // LX*
|
2189 | |
FMS ( 0, 6, 9,14, 9, *u = "Kaby Lake", *f = "optim of Skylake", *p = "14nm+");
|
2190 | |
FMS ( 0, 6, 9,14, 10, *u = "Coffee Lake", *ciu = TRUE, *f = "optim of Kaby Lake, optim of Skylake", *p = "14nm++");
|
2191 | |
FMS ( 0, 6, 9,14, 11, *u = "Coffee Lake", *ciu = TRUE, *f = "optim of Kaby Lake, optim of Skylake", *p = "14nm++");
|
2192 | |
FMS ( 0, 6, 9,14, 12, *u = "Coffee Lake", *ciu = TRUE, *f = "optim of Kaby Lake, optim of Skylake", *p = "14nm++");
|
2193 | |
FMS ( 0, 6, 9,14, 13, *u = "Coffee Lake", *ciu = TRUE, *f = "optim of Kaby Lake, optim of Skylake", *p = "14nm++");
|
2194 | |
FM ( 0, 6, 9,14, *u = "Kaby Lake / Coffee Lake", *f = "optim of Skylake", *p = "14nm+/14nm++");
|
2195 | |
FM ( 0, 6, 9,15, *u = "Sunny Cove", *f = "Sunny Cove", *p = "10nm+"); // undocumented, but (engr?) sample via instlatx64 from Komachi_ENSAKA
|
2196 | |
FM ( 0, 6, 10, 5, *u = "Kaby Lake", *f = "optim of Skylake", *p = "14nm+++"); // LX*
|
2197 | |
FM ( 0, 6, 10, 6, *u = "Kaby Lake", *f = "optim of Skylake", *p = "14nm+++"); // no spec update; only instlatx64 example
|
2198 | |
FM ( 0, 6, 10, 7, *u = "Cypress Cove", *f = "backport of Sunny Cove", *p = "14nm+++"); // LX*
|
2199 | |
FM ( 0, 6, 10, 8, *u = "Cypress Cove", *f = "backport of Sunny Cove", *p = "14nm+++"); // undocumented, but (engr?) sample via instlatx64 from Komachi_ENSAKA
|
2200 | |
FM ( 0, 6, 10,10, *u = "Redwood Cove", *f = "Golden Cove", *p = "Intel 4"); // MSR_CPUID_table*; DPTF*, LX* (but -L); (engr?) sample via instlatx64 from Komachi_ENSAKA
|
2201 | |
FM ( 0, 6, 10,11, *u = "Redwood Cove", *f = "Golden Cove", *p = "Intel 4"); // DPTF*
|
2202 | |
FM ( 0, 6, 10,12, *u = "Redwood Cove", *f = "Golden Cove", *p = "Intel 4"); // MSR_CPUID_table*; (engr?) sample via instlatx64 from Komachi_ENSAKA
|
2203 | |
FM ( 0, 6, 10,13, *u = "Granite Rapids", *f = "Golden Cove", *p = "Intel 4"); // MSR_CPUID_table*; LX*; (engr?) sample via instlatx64 from Komachi_ENSAKA
|
2204 | |
FM ( 0, 6, 10,14, *u = "Granite Rapids", *f = "Golden Cove", *p = "Intel 4"); // MSR_CPUID_table*; LX*
|
2205 | |
FM ( 0, 6, 10,15, *u = "Sierra Forest"); // MSR_CPUID_table*; LX*; (engr?) sample via instlatx64 from Komachi_ENSAKA
|
2206 | |
FM ( 0, 6, 11, 5, *u = "Redwood Cove", *f = "Golden Cove", *p = "Intel 4"); // MSR_CPUID_table*
|
2207 | |
FM ( 0, 6, 11, 6, *u = "Crestmont", *p = "Intel 7"); // MSR_CPUID_table*; LX*; (although assumption that Grand Ridge is Crestmont)
|
2208 | |
FMQ ( 0, 6, 11, 7, Ha, *u = "Gracemont", *p = "Intel 7"); // MSR_CPUID_table*; LX*; DPTF*
|
2209 | |
FMQ ( 0, 6, 11, 7, Hc, *u = "Raptor Cove", *f = "optim of Golden Cove", *p = "Intel 7"); // MSR_CPUID_table*; LX*; DPTF*
|
2210 | |
FMQ ( 0, 6, 11,10, Ha, *u = "Gracemont", *p = "Intel 7"); // DPTF*; Coreboot*
|
2211 | |
FMQ ( 0, 6, 11,10, Hc, *u = "Raptor Cove", *f = "optim of Golden Cove", *p = "Intel 7"); // DPTF*; Coreboot*
|
2212 | |
// (0,6),(11,13) is reserved for whatever not-yet-named uarch underpins
|
2213 | |
// Lunar Lake
|
2214 | |
FM ( 0, 6, 11,14, *u = "Golden Cove", *p = "Intel 7"); // Coreboot*, PDTF*
|
2215 | |
FMQ ( 0, 6, 11,15, Ha, *u = "Gracemont", *p = "Intel 7"); // MSR_CPUID_table*
|
2216 | |
FMQ ( 0, 6, 11,15, Hc, *u = "Raptor Cove", *f = "optim of Golden Cove", *p = "Intel 7"); // MSR_CPUID_table*
|
2217 | |
FM ( 0, 6, 12,15, *u = "Emerald Rapids", *p = "Intel 7"); // MSR_CPUID_table*; LX*
|
|
2142 |
FM ( 0, 6, 0, 5, *f = "P6 Pentium II", *p = ".25um");
|
|
2143 |
FM ( 0, 6, 0, 6, *f = "P6 Pentium II", *p = "L2 cache");
|
|
2144 |
FM ( 0, 6, 0, 7, *f = "P6 Pentium III", *p = ".25um");
|
|
2145 |
FM ( 0, 6, 0, 8, *f = "P6 Pentium III", *p = ".18um");
|
|
2146 |
FM ( 0, 6, 0, 9, *f = "P6 Pentium M", *p = ".13um");
|
|
2147 |
FM ( 0, 6, 0,10, *f = "P6 Pentium III", *p = ".18um");
|
|
2148 |
FM ( 0, 6, 0,11, *f = "P6 Pentium III", *p = ".13um");
|
|
2149 |
FM ( 0, 6, 0,13, *u = "Dothan", *f = "P6 Pentium M"); // *p depends on core
|
|
2150 |
FM ( 0, 6, 0,14, *u = "Yonah", *f = "P6 Pentium M", *p = "65nm");
|
|
2151 |
FM ( 0, 6, 0,15, *u = "Merom", *f = "Core", *p = "65nm");
|
|
2152 |
FM ( 0, 6, 1, 5, *u = "Dothan", *f = "P6 Pentium M", *p = "90nm");
|
|
2153 |
FM ( 0, 6, 1, 6, *u = "Merom", *f = "Core", *p = "65nm");
|
|
2154 |
FM ( 0, 6, 1, 7, *u = "Penryn", *f = "Core", *p = "45nm");
|
|
2155 |
FM ( 0, 6, 1,10, *u = "Nehalem", *f = "Nehalem", *p = "45nm");
|
|
2156 |
FM ( 0, 6, 1,12, *u = "Bonnell", *p = "45nm");
|
|
2157 |
FM ( 0, 6, 1,13, *u = "Penryn", *f = "Core", *p = "45nm");
|
|
2158 |
FM ( 0, 6, 1,14, *u = "Nehalem", *f = "Nehalem", *p = "45nm");
|
|
2159 |
FM ( 0, 6, 1,15, *u = "Nehalem", *f = "Nehalem", *p = "45nm");
|
|
2160 |
FM ( 0, 6, 2, 5, *u = "Westmere", *f = "shrink of Nehalem", *p = "32nm");
|
|
2161 |
FM ( 0, 6, 2, 6, *u = "Bonnell", *p = "45nm");
|
|
2162 |
FM ( 0, 6, 2, 7, *u = "Saltwell", *p = "32nm");
|
|
2163 |
FM ( 0, 6, 2,10, *u = "Sandy Bridge", *ciu = TRUE, *f = "Sandy Bridge", *p = "32nm");
|
|
2164 |
FM ( 0, 6, 2,12, *u = "Westmere", *f = "shrink of Nehalem", *p = "32nm");
|
|
2165 |
FM ( 0, 6, 2,13, *u = "Sandy Bridge", *ciu = TRUE, *f = "Sandy Bridge", *p = "32nm");
|
|
2166 |
FM ( 0, 6, 2,14, *u = "Nehalem", *f = "Nehalem", *p = "45nm");
|
|
2167 |
FM ( 0, 6, 2,15, *u = "Westmere", *f = "shrink of Nehalem", *p = "32nm");
|
|
2168 |
FM ( 0, 6, 3, 5, *u = "Saltwell", *p = "14nm");
|
|
2169 |
FM ( 0, 6, 3, 6, *u = "Saltwell", *p = "32nm");
|
|
2170 |
FM ( 0, 6, 3, 7, *u = "Silvermont", *p = "22nm");
|
|
2171 |
FM ( 0, 6, 3,10, *u = "Ivy Bridge", *ciu = TRUE, *f = "shrink of Sandy Bridge", *p = "22nm");
|
|
2172 |
FM ( 0, 6, 3,12, *u = "Haswell", *ciu = TRUE, *f = "Haswell", *p = "22nm");
|
|
2173 |
FM ( 0, 6, 3,13, *u = "Broadwell", *ciu = TRUE, *f = "shrink of Haswell", *p = "14nm");
|
|
2174 |
FM ( 0, 6, 3,14, *u = "Ivy Bridge", *ciu = TRUE, *f = "shrink of Sandy Bridge", *p = "22nm");
|
|
2175 |
FM ( 0, 6, 3,15, *u = "Haswell", *ciu = TRUE, *f = "Haswell", *p = "22nm");
|
|
2176 |
FM ( 0, 6, 4, 5, *u = "Haswell", *ciu = TRUE, *f = "Haswell", *p = "22nm");
|
|
2177 |
FM ( 0, 6, 4, 6, *u = "Haswell", *ciu = TRUE, *f = "Haswell", *p = "22nm");
|
|
2178 |
FM ( 0, 6, 4, 7, *u = "Broadwell", *ciu = TRUE, *f = "shrink of Haswell", *p = "14nm");
|
|
2179 |
FM ( 0, 6, 4,10, *u = "Silvermont", *p = "22nm"); // no docs, but /proc/cpuinfo seen in wild
|
|
2180 |
FM ( 0, 6, 4,12, *u = "Airmont", *p = "14nm");
|
|
2181 |
FM ( 0, 6, 4,13, *u = "Silvermont", *p = "22nm");
|
|
2182 |
FMS ( 0, 6, 4,14, 8, *u = "Kaby Lake", *f = "optim of Skylake", *p = "14nm+");
|
|
2183 |
FM ( 0, 6, 4,14, *u = "Skylake", *ciu = TRUE, *f = "Skylake", *p = "14nm");
|
|
2184 |
FM ( 0, 6, 4,15, *u = "Broadwell", *ciu = TRUE, *f = "shrink of Haswell", *p = "14nm");
|
|
2185 |
FMQ ( 0, 6, 5, 5, iM, *u = "Jintide Gen1", *ciu = TRUE); // undocumented; only instlatx64 example
|
|
2186 |
FMS ( 0, 6, 5, 5, 6, *u = "Cascade Lake", *ciu = TRUE, *f = "optim of Skylake", *p = "14nm++"); // no docs, but example from Greg Stewart
|
|
2187 |
FMS ( 0, 6, 5, 5, 7, *u = "Cascade Lake", *ciu = TRUE, *f = "optim of Skylake", *p = "14nm++");
|
|
2188 |
FMS ( 0, 6, 5, 5, 10, *u = "Cooper Lake", *ciu = TRUE, *f = "optim of Cascade Lake, optim of Skylake", *p = "14nm++");
|
|
2189 |
FM ( 0, 6, 5, 5, *u = "Skylake", *ciu = TRUE, *f = "Skylake", *p = "14nm");
|
|
2190 |
FM ( 0, 6, 5, 6, *u = "Broadwell", *ciu = TRUE, *f = "shrink of Haswell", *p = "14nm");
|
|
2191 |
FM ( 0, 6, 5, 7, *u = "Knights Landing", *ciu = TRUE, *p = "14nm");
|
|
2192 |
FM ( 0, 6, 5,10, *u = "Silvermont", *p = "22nm"); // no spec update; only MSR_CPUID_table* so far
|
|
2193 |
FM ( 0, 6, 5,12, *u = "Goldmont", *p = "14nm"); // no spec update for Atom; only MSR_CPUID_table* so far
|
|
2194 |
FM ( 0, 6, 5,13, *u = "Silvermont", *p = "22nm"); // no spec update; only MSR_CPUID_table* so far
|
|
2195 |
FMS ( 0, 6, 5,14, 8, *u = "Kaby Lake", *f = "optim of Skylake", *p = "14nm+");
|
|
2196 |
FM ( 0, 6, 5,14, *u = "Skylake", *ciu = TRUE, *f = "Skylake", *p = "14nm");
|
|
2197 |
FM ( 0, 6, 5,15, *u = "Goldmont", *p = "14nm");
|
|
2198 |
FM ( 0, 6, 6, 6, *u = "Palm Cove", *f = "Palm Cove", *p = "10nm"); // no spec update; only MSR_CPUID_table* so far
|
|
2199 |
FM ( 0, 6, 6, 7, *u = "Palm Cove", *f = "Palm Cove", *p = "10nm"); // DPTF*
|
|
2200 |
FM ( 0, 6, 6,10, *u = "Sunny Cove", *f = "Sunny Cove", *p = "10nm+");
|
|
2201 |
FM ( 0, 6, 6,12, *u = "Sunny Cove", *f = "Sunny Cove", *p = "10nm+"); // no spec update; only MSR_CPUID_table* so far; DPTF* claims this is Meteor Lake S => Redwood Cove
|
|
2202 |
FM ( 0, 6, 6,14, *u = "Airmont", *p = "14nm"); // no spec update; only Intel's "Retpoline: A Branch Target Injection Mitigation"
|
|
2203 |
FM ( 0, 6, 7, 5, *u = "Airmont", *p = "14nm"); // no spec update; whispers & rumors
|
|
2204 |
FM ( 0, 6, 7,10, *u = "Goldmont Plus", *p = "14nm");
|
|
2205 |
FM ( 0, 6, 7,13, *u = "Sunny Cove", *f = "Sunny Cove", *p = "10nm+"); // no spec update; only MSR_CPUID_table* so far
|
|
2206 |
FM ( 0, 6, 7,14, *u = "Sunny Cove", *f = "Sunny Cove", *p = "10nm+");
|
|
2207 |
FM ( 0, 6, 8, 5, *u = "Knights Mill", *ciu = TRUE, *p = "14nm"); // no spec update; only MSR_CPUID_table* so far
|
|
2208 |
FM ( 0, 6, 8, 6, *u = "Tremont", *p = "10nm"); // LX*
|
|
2209 |
FMQ ( 0, 6, 8,10, Ha, *u = "Tremont", *p = "10nm"); // no spec update; LX*
|
|
2210 |
FMQ ( 0, 6, 8,10, Hc, *u = "Sunny Cove", *p = "10nm"); // no spec update; LX*
|
|
2211 |
FM ( 0, 6, 8,12, *u = "Willow Cove", *f = "optim of Sunny Cove", *p = "10nm++"); // no spec update; only MSR_CPUID_table* so far
|
|
2212 |
FM ( 0, 6, 8,13, *u = "Willow Cove", *f = "optim of Sunny Cove", *p = "10nm++"); // no spec update; only MSR_CPUID_table* so far
|
|
2213 |
FM ( 0, 6, 8,14, *u = "Kaby Lake", *f = "optim of Skylake", *p = "14nm+/14nm++");
|
|
2214 |
FM ( 0, 6, 8,15, *u = "Sapphire Rapids", *ciu = TRUE, *f = "Golden Cove", *p = "Intel 7"); // LX*
|
|
2215 |
FM ( 0, 6, 9, 6, *u = "Tremont", *p = "10nm"); // LX*
|
|
2216 |
FMQ ( 0, 6, 9, 7, Ha, *u = "Gracemont", *p = "Intel 7");
|
|
2217 |
FMQ ( 0, 6, 9, 7, Hc, *u = "Golden Cove", *p = "Intel 7");
|
|
2218 |
FMQ ( 0, 6, 9, 7, Hz, *u = "Golden Cove", *p = "Intel 7");
|
|
2219 |
FMQ ( 0, 6, 9,10, Ha, *u = "Gracemont", *p = "Intel 7"); // Coreboot*
|
|
2220 |
FMQ ( 0, 6, 9,10, Hc, *u = "Golden Cove", *p = "Intel 7"); // Coreboot*
|
|
2221 |
FM ( 0, 6, 9,12, *u = "Tremont", *p = "10nm"); // LX*
|
|
2222 |
FM ( 0, 6, 9,13, *u = "Sunny Cove", *f = "Sunny Cove", *p = "10nm+"); // LX*
|
|
2223 |
FMS ( 0, 6, 9,14, 9, *u = "Kaby Lake", *f = "optim of Skylake", *p = "14nm+");
|
|
2224 |
FMS ( 0, 6, 9,14, 10, *u = "Coffee Lake", *ciu = TRUE, *f = "optim of Kaby Lake, optim of Skylake", *p = "14nm++");
|
|
2225 |
FMS ( 0, 6, 9,14, 11, *u = "Coffee Lake", *ciu = TRUE, *f = "optim of Kaby Lake, optim of Skylake", *p = "14nm++");
|
|
2226 |
FMS ( 0, 6, 9,14, 12, *u = "Coffee Lake", *ciu = TRUE, *f = "optim of Kaby Lake, optim of Skylake", *p = "14nm++");
|
|
2227 |
FMS ( 0, 6, 9,14, 13, *u = "Coffee Lake", *ciu = TRUE, *f = "optim of Kaby Lake, optim of Skylake", *p = "14nm++");
|
|
2228 |
FM ( 0, 6, 9,14, *u = "Kaby Lake / Coffee Lake", *f = "optim of Skylake", *p = "14nm+/14nm++");
|
|
2229 |
FM ( 0, 6, 9,15, *u = "Sunny Cove", *f = "Sunny Cove", *p = "10nm+"); // undocumented, but (engr?) sample via instlatx64 from Komachi_ENSAKA
|
|
2230 |
FM ( 0, 6, 10, 5, *u = "Kaby Lake", *f = "optim of Skylake", *p = "14nm+++"); // LX*
|
|
2231 |
FM ( 0, 6, 10, 6, *u = "Kaby Lake", *f = "optim of Skylake", *p = "14nm+++"); // no spec update; only instlatx64 example
|
|
2232 |
FM ( 0, 6, 10, 7, *u = "Cypress Cove", *f = "backport of Sunny Cove", *p = "14nm+++"); // LX*
|
|
2233 |
FM ( 0, 6, 10, 8, *u = "Cypress Cove", *f = "backport of Sunny Cove", *p = "14nm+++"); // undocumented, but (engr?) sample via instlatx64 from Komachi_ENSAKA
|
|
2234 |
FMQ ( 0, 6, 10,10, Ha, *u = "Crestmont", *p = "Intel 4"); // MSR_CPUID_table*; DPTF*, LX* (but -L); (engr?) sample via instlatx64 from Komachi_ENSAKA
|
|
2235 |
FMQ ( 0, 6, 10,10, Hc, *u = "Redwood Cove", *f = "shrink of Raptor Cove, optim of Golden Cove", *p = "Intel 4"); // MSR_CPUID_table*; DPTF*, LX* (but -L); (engr?) sample via instlatx64 from Komachi_ENSAKA
|
|
2236 |
FMQ ( 0, 6, 10,11, Ha, *u = "Crestmont", *p = "Intel 4"); // DPTF*
|
|
2237 |
FMQ ( 0, 6, 10,11, Hc, *u = "Redwood Cove", *f = "shrink of Raptor Cove, optim of Golden Cove", *p = "Intel 4"); // DPTF*
|
|
2238 |
FMQ ( 0, 6, 10,12, Ha, *u = "Crestmont", *p = "Intel 4"); // MSR_CPUID_table*; (engr?) sample via instlatx64 from Komachi_ENSAKA
|
|
2239 |
FMQ ( 0, 6, 10,12, Hc, *u = "Redwood Cove", *f = "shrink of Raptor Cove, optim of Golden Cove", *p = "Intel 4"); // MSR_CPUID_table*; (engr?) sample via instlatx64 from Komachi_ENSAKA
|
|
2240 |
FM ( 0, 6, 10,13, *u = "Granite Rapids", *ciu = TRUE, *f = "Redwood Cove, shrink of Raptor Cove, optim of Golden Cove", *p = "Intel 4"); // MSR_CPUID_table*; LX*; (engr?) sample via instlatx64 from Komachi_ENSAKA
|
|
2241 |
FM ( 0, 6, 10,14, *u = "Granite Rapids", *ciu = TRUE, *f = "Redwood Cove, shrink of Raptor Cove, optim of Golden Cove", *p = "Intel 4"); // MSR_CPUID_table*; LX*
|
|
2242 |
FM ( 0, 6, 10,15, *u = "Sierra Forest"); // MSR_CPUID_table*; LX*; (engr?) sample via instlatx64 from Komachi_ENSAKA
|
|
2243 |
FMQ ( 0, 6, 11, 5, Ha, *u = "Crestmont", *p = "Intel 4"); // MSR_CPUID_table*
|
|
2244 |
FMQ ( 0, 6, 11, 5, Hc, *u = "Redwood Cove", *f = "optim of Raptor Cove, optim of Golden Cove", *p = "Intel 4"); // MSR_CPUID_table*
|
|
2245 |
FM ( 0, 6, 11, 6, *u = "Crestmont", *p = "Intel 7"); // MSR_CPUID_table*; LX*; (although assumption that Grand Ridge is Crestmont)
|
|
2246 |
FMQ ( 0, 6, 11, 7, Ha, *u = "Gracemont", *p = "Intel 7"); // MSR_CPUID_table*; LX*; DPTF*
|
|
2247 |
FMQ ( 0, 6, 11, 7, Hc, *u = "Raptor Cove", *f = "optim of Golden Cove", *p = "Intel 7"); // MSR_CPUID_table*; LX*; DPTF*
|
|
2248 |
FMQ ( 0, 6, 11,10, Ha, *u = "Gracemont", *p = "Intel 7"); // DPTF*; Coreboot*
|
|
2249 |
FMQ ( 0, 6, 11,10, Hc, *u = "Raptor Cove", *f = "optim of Golden Cove", *p = "Intel 7"); // DPTF*; Coreboot*
|
|
2250 |
// (0,6),(11,13) is reserved for whatever not-yet-named uarch underpins Lunar Lake
|
|
2251 |
FMQ ( 0, 6, 11,14, Ha, *u = "Gracemont", *p = "Intel 7");
|
|
2252 |
FMQ ( 0, 6, 11,14, Hc, *u = "Golden Cove", *p = "Intel 7"); // possibly no P-cores ever for this model
|
|
2253 |
FMQ ( 0, 6, 11,15, Ha, *u = "Gracemont", *p = "Intel 7"); // MSR_CPUID_table*
|
|
2254 |
FMQ ( 0, 6, 11,15, Hc, *u = "Raptor Cove", *f = "optim of Golden Cove", *p = "Intel 7"); // MSR_CPUID_table*
|
|
2255 |
FMQ ( 0, 6, 12, 6, Ha, *u = "Skymont", *p = "Intel 20A"); // LX*
|
|
2256 |
FMQ ( 0, 6, 12, 6, Hc, *u = "Lion Cove", *p = "Intel 20A"); // LX*
|
|
2257 |
FM ( 0, 6, 12,15, *u = "Emerald Rapids", *ciu = TRUE, *f = "Raptor Cove, optim of Golden Cove", *p = "Intel 7"); // MSR_CPUID_table*; LX*
|
2218 | 2258 |
F ( 0, 7, *u = "Itanium");
|
2219 | |
FM ( 0,11, 0, 0, *u = "Knights Ferry", *ciu = TRUE, *f = "K1OM", *p = "45nm"); // found only on en.wikichip.org
|
2220 | |
FM ( 0,11, 0, 1, *u = "Knights Corner", *ciu = TRUE, *f = "K1OM", *p = "22nm");
|
2221 | |
FM ( 0,15, 0, 0, *u = "Willamette", *f = "Netburst", *p = ".18um");
|
2222 | |
FM ( 0,15, 0, 1, *u = "Willamette", *f = "Netburst", *p = ".18um");
|
2223 | |
FM ( 0,15, 0, 2, *u = "Northwood", *f = "Netburst", *p = ".13um");
|
2224 | |
FM ( 0,15, 0, 3, *u = "Prescott", *f = "Netburst", *p = "90nm");
|
2225 | |
FM ( 0,15, 0, 4, *u = "Prescott", *f = "Netburst", *p = "90nm");
|
2226 | |
FM ( 0,15, 0, 6, *u = "Cedar Mill", *f = "Netburst", *p = "65nm");
|
|
2259 |
FM ( 0,11, 0, 0, *u = "Knights Ferry", *ciu = TRUE, *f = "K1OM", *p = "45nm"); // found only on en.wikichip.org
|
|
2260 |
FM ( 0,11, 0, 1, *u = "Knights Corner", *ciu = TRUE, *f = "K1OM", *p = "22nm");
|
|
2261 |
FM ( 0,15, 0, 0, *u = "Willamette", *f = "Netburst", *p = ".18um");
|
|
2262 |
FM ( 0,15, 0, 1, *u = "Willamette", *f = "Netburst", *p = ".18um");
|
|
2263 |
FM ( 0,15, 0, 2, *u = "Northwood", *f = "Netburst", *p = ".13um");
|
|
2264 |
FM ( 0,15, 0, 3, *u = "Prescott", *f = "Netburst", *p = "90nm");
|
|
2265 |
FM ( 0,15, 0, 4, *u = "Prescott", *f = "Netburst", *p = "90nm");
|
|
2266 |
FM ( 0,15, 0, 6, *u = "Cedar Mill", *f = "Netburst", *p = "65nm");
|
2227 | 2267 |
F ( 0,15, *f = "Netburst");
|
2228 | |
FM ( 1,15, 0, 0, *u = "Itanium2", *p = ".18um");
|
2229 | |
FM ( 1,15, 0, 1, *u = "Itanium2", *p = ".13um");
|
2230 | |
FM ( 1,15, 0, 2, *u = "Itanium2", *p = ".13um");
|
|
2268 |
FM ( 1,15, 0, 0, *u = "Itanium2", *p = ".18um");
|
|
2269 |
FM ( 1,15, 0, 1, *u = "Itanium2", *p = ".13um");
|
|
2270 |
FM ( 1,15, 0, 2, *u = "Itanium2", *p = ".13um");
|
2231 | 2271 |
F ( 1,15, *u = "Itanium2");
|
2232 | |
F ( 2, 0, *u = "Itanium2", *p = "90nm");
|
|
2272 |
F ( 2, 0, *u = "Itanium2", *p = "90nm");
|
2233 | 2273 |
F ( 2, 1, *u = "Itanium2");
|
2234 | 2274 |
DEFAULT ((void)NULL);
|
2235 | 2275 |
}
|
|
3423 | 3463 |
FMS ( 0, 6, 6, 6, 3, "Intel Core (Cannon Lake D0)");
|
3424 | 3464 |
FM ( 0, 6, 6, 6, "Intel Core (Cannon Lake)");
|
3425 | 3465 |
FM ( 0, 6, 6, 7, "Intel Core (Cannon Lake)"); // DPTF*
|
3426 | |
FMSQ( 0, 6, 6,10, 5, sS, "Intel Scalable (3rd Gen) Bronze/Silver/Gold/Platinum (Ice Lake C0)"); // ILPMDF* 20210608
|
3427 | |
FMSQ( 0, 6, 6,10, 6, sS, "Intel Scalable (3rd Gen) Bronze/Silver/Gold/Platinum (Ice Lake D2/M1)");
|
3428 | |
FMQ ( 0, 6, 6,10, sS, "Intel Scalable (3rd Gen) Bronze/Silver/Gold/Platinum (Ice Lake)");
|
3429 | |
FM ( 0, 6, 6,10, "Intel (unknown type) (Ice Lake)");
|
|
3466 |
FMSQ( 0, 6, 6,10, 5, sS, "Intel Scalable (3rd Gen) Bronze/Silver/Gold/Platinum (Ice Lake-SP C0)"); // ILPMDF* 20210608
|
|
3467 |
FMS ( 0, 6, 6,10, 5, "Intel Xeon (unknown type) (Ice Lake-SP C0)"); // ILPMDF* 20210608
|
|
3468 |
FMSQ( 0, 6, 6,10, 6, sS, "Intel Scalable (3rd Gen) Bronze/Silver/Gold/Platinum (Ice Lake-SP D2/M1)");
|
|
3469 |
FMS ( 0, 6, 6,10, 6, "Intel Xeon (unknown type) (Ice Lake-SP D2/M1)");
|
|
3470 |
FMQ ( 0, 6, 6,10, sS, "Intel Scalable (3rd Gen) Bronze/Silver/Gold/Platinum (Ice Lake-SP)");
|
|
3471 |
FM ( 0, 6, 6,10, "Intel Xeon (unknown type) (Ice Lake-SP)");
|
3430 | 3472 |
// No spec update; MSR_CPUID_table* so far
|
3431 | 3473 |
// DPTF* claims this is Meteor Lake S
|
3432 | 3474 |
// ILPMDF* 20221108 claims ICL-D (Ice Lake Xeon D), and provides B0 stepping.
|
|
3528 | 3570 |
FMS ( 0, 6, 8,14, 13, "Intel (unknown type) (Whiskey Lake-U V0)"); // ILPMDF* 20190312
|
3529 | 3571 |
FM ( 0, 6, 8,14, "Intel Core (unknown type) (Kaby Lake / Amber Lake-Y / Whiskey Lake-U / Comet Lake-U)");
|
3530 | 3572 |
// No spec update; MSR_CPUID_table*, LX*
|
|
3573 |
// coreboot*, based on confidential Sapphire Rapids External Design
|
|
3574 |
// Specification doc (612246), provides steppings D & E0.
|
3531 | 3575 |
// ILPMDF* 20230214 provides steppings E2, E3, E4, E5.
|
3532 | 3576 |
// ILPMDF* 20230214 mentions that stepping 8 also is Sapphire Rapids HBM
|
3533 | 3577 |
// (Xeon Max) B3. Maybe describe that better if I can distinguish them.
|
|
3578 |
// instlatx64 provides a Xeon W sample, but I've seen no spec update for it. Assuming they could be any stepping.
|
|
3579 |
FMSQ( 0, 6, 8,15, 3, sS, "Intel Scalable (4th Gen) Bronze/Silver/Gold/Platinum (Sapphire Rapids D)");
|
|
3580 |
FMSQ( 0, 6, 8,15, 3, sX, "Intel Xeon W 2400/3400 (Sapphire Rapids D)");
|
|
3581 |
FMS ( 0, 6, 8,15, 3, "Intel Xeon (unknown type) (Sapphire Rapids D)");
|
|
3582 |
FMSQ( 0, 6, 8,15, 4, sS, "Intel Scalable (4th Gen) Bronze/Silver/Gold/Platinum (Sapphire Rapids E0)");
|
|
3583 |
FMSQ( 0, 6, 8,15, 4, sX, "Intel Xeon W 2400/3400 (Sapphire Rapids E0)");
|
|
3584 |
FMS ( 0, 6, 8,15, 4, "Intel Xeon (unknown type) (Sapphire Rapids E0)");
|
3534 | 3585 |
FMSQ( 0, 6, 8,15, 5, sS, "Intel Scalable (4th Gen) Bronze/Silver/Gold/Platinum (Sapphire Rapids E2)");
|
|
3586 |
FMSQ( 0, 6, 8,15, 5, sX, "Intel Xeon W 2400/3400 (Sapphire Rapids E2)");
|
3535 | 3587 |
FMS ( 0, 6, 8,15, 5, "Intel Xeon (unknown type) (Sapphire Rapids E2)");
|
3536 | 3588 |
FMSQ( 0, 6, 8,15, 6, sS, "Intel Scalable (4th Gen) Bronze/Silver/Gold/Platinum (Sapphire Rapids E3)");
|
|
3589 |
FMSQ( 0, 6, 8,15, 6, sX, "Intel Xeon W 2400/3400 (Sapphire Rapids E3)");
|
3537 | 3590 |
FMS ( 0, 6, 8,15, 6, "Intel Xeon (unknown type) (Sapphire Rapids E3)");
|
3538 | 3591 |
FMSQ( 0, 6, 8,15, 7, sS, "Intel Scalable (4th Gen) Bronze/Silver/Gold/Platinum (Sapphire Rapids E4)");
|
|
3592 |
FMSQ( 0, 6, 8,15, 7, sX, "Intel Xeon W 2400/3400 (Sapphire Rapids E4)");
|
3539 | 3593 |
FMS ( 0, 6, 8,15, 7, "Intel Xeon (unknown type) (Sapphire Rapids E4)");
|
3540 | 3594 |
FMSQ( 0, 6, 8,15, 8, sS, "Intel Scalable (4th Gen) Bronze/Silver/Gold/Platinum (Sapphire Rapids E5/B3)");
|
|
3595 |
FMSQ( 0, 6, 8,15, 8, sX, "Intel Xeon W 2400/3400 (Sapphire Rapids E5/B3)");
|
3541 | 3596 |
FMS ( 0, 6, 8,15, 8, "Intel Xeon (unknown type) (Sapphire Rapids E5/B3)");
|
3542 | 3597 |
FMQ ( 0, 6, 8,15, sS, "Intel Scalable (4th Gen) Bronze/Silver/Gold/Platinum (Sapphire Rapids)");
|
|
3598 |
FMQ ( 0, 6, 8,15, sX, "Intel Xeon W 2400/3400 (Sapphire Rapids)");
|
3543 | 3599 |
FM ( 0, 6, 8,15, "Intel Xeon (unknown type) (Sapphire Rapids)");
|
3544 | 3600 |
// LX*. Coreboot* provides stepping.
|
3545 | 3601 |
FMSQ( 0, 6, 9, 6, 0, dC, "Intel Celeron J6400 / N6400 (Elkhart Lake A0)");
|
|
3591 | 3647 |
FMQ ( 0, 6, 9, 7, dP, "Intel Pentium Gold G7400 (Alder Lake-S)"); // no docs on Pentium Gold version; instlatx64 sample
|
3592 | 3648 |
FM ( 0, 6, 9, 7, "Intel (unknown type) (Alder Lake-S/P/H/U)");
|
3593 | 3649 |
// MSR_CPUID_table*, Coreboot*. Coreboot* provides steppings.
|
3594 | |
// ILPMDF* 20220510 (and later) claim steppings 3 & 4 *both* are stepping L0. Cut&past error?
|
|
3650 |
// ILPMDF* 20220510 (and later) claim steppings 3 & 4 *both* are stepping L0. Cut&paste error?
|
3595 | 3651 |
FMSQ( 0, 6, 9,10, 0, Ha, "Intel Core i*-12000 E-core (Alder Lake J0)");
|
3596 | 3652 |
FMSQ( 0, 6, 9,10, 0, Hc, "Intel Core i*-12000 P-core (Alder Lake J0)");
|
3597 | 3653 |
FMSQ( 0, 6, 9,10, 0, dc, "Intel Core i*-12000 (Alder Lake J0)");
|
|
3704 | 3760 |
FM ( 0, 6, 10, 8, "Intel (unknown type) (Rocket Lake)"); // MSR_CPUID_table*
|
3705 | 3761 |
FMS ( 0, 6, 10,10, 0, "Intel (unknown type) (Meteor Lake-M A0)"); // DPTF*; undocumented, but (engr?) sample via instlatx64 from Komachi_ENSAKA; Coreboot* provides steppings.
|
3706 | 3762 |
FMS ( 0, 6, 10,10, 1, "Intel (unknown type) (Meteor Lake-M A0)"); // DPTF*; undocumented, but (engr?) sample via instlatx64 from Komachi_ENSAKA; Coreboot* provides steppings.
|
|
3763 |
FMS ( 0, 6, 10,10, 2, "Intel (unknown type) (Meteor Lake-M B0)"); // DPTF*; Coreboot* provides steppings
|
3707 | 3764 |
FM ( 0, 6, 10,10, "Intel (unknown type) (Meteor Lake-M)"); // MSR_CPUID_table*; DPTF*, LX* (but -L); (engr?) sample via instlatx64 from Komachi_ENSAKA
|
3708 | 3765 |
FM ( 0, 6, 10,11, "Intel (unknown type) (Meteor Lake-N)"); // DPTF*
|
3709 | 3766 |
FM ( 0, 6, 10,12, "Intel (unknown type) (Meteor Lake-S)"); // MSR_CPUID_table*; LX*; (engr?) sample via instlatx64 from Komachi_ENSAKA
|
|
3712 | 3769 |
FM ( 0, 6, 10,15, "Intel (unknown type) (Sierra Forest)"); // MSR_CPUID_table*; (engr?) sample via instlatx64 from Komachi_ENSAKA
|
3713 | 3770 |
FM ( 0, 6, 11, 5, "Intel (unknown type) (Meteor Lake)"); // MSR_CPUID_table*
|
3714 | 3771 |
FM ( 0, 6, 11, 6, "Intel Atom (Grand Ridge)"); // MSR_CPUID_table*
|
|
3772 |
// Intel doc 743844 provides stepping 1, with name!
|
3715 | 3773 |
FMSQ( 0, 6, 11, 7, 1, Ha, "Intel Core i*-13000 E-core (Raptor Lake-S/HX B0)");
|
3716 | 3774 |
FMSQ( 0, 6, 11, 7, 1, Hc, "Intel Core i*-13000 P-core (Raptor Lake-S/HX B0)");
|
3717 | 3775 |
FMSQ( 0, 6, 11, 7, 1, dc, "Intel Core i*-13000 (Raptor Lake-S/HX B0)");
|
|
3720 | 3778 |
FMQ ( 0, 6, 11, 7, Hc, "Intel Core i*-13000 P-core (Raptor Lake-S/HX)");
|
3721 | 3779 |
FMQ ( 0, 6, 11, 7, dc, "Intel Core i*-13000 (Raptor Lake-S/HX)");
|
3722 | 3780 |
FM ( 0, 6, 11, 7, "Intel (unknown type) (Raptor Lake-S/HX)");
|
3723 | |
FMSQ( 0, 6, 11,10, 2, Ha, "Intel Core i*-13000 E-core (Raptor Lake-P J0)"); // ILPMDF* 20230214, instlatx64 sample
|
3724 | |
FMSQ( 0, 6, 11,10, 2, Hc, "Intel Core i*-13000 P-core (Raptor Lake-P J0)"); // ILPMDF* 20230214, instlatx64 sample
|
3725 | |
FMSQ( 0, 6, 11,10, 2, dc, "Intel Core i*-13000 (Raptor Lake-P J0)"); // ILPMDF* 20230214
|
3726 | |
FMS ( 0, 6, 11,10, 2, "Intel (unknown type) (Raptor Lake-P J0)"); // ILPMDF* 20230214
|
3727 | |
FMSQ( 0, 6, 11,10, 3, Ha, "Intel Core i*-13000 E-core (Raptor Lake-P Q0)"); // ILPMDF* 20230214
|
3728 | |
FMSQ( 0, 6, 11,10, 3, Hc, "Intel Core i*-13000 P-core (Raptor Lake-P Q0)"); // ILPMDF* 20230214
|
3729 | |
FMSQ( 0, 6, 11,10, 3, dc, "Intel Core i*-13000 (Raptor Lake-P Q0)"); // ILPMDF* 20230214
|
3730 | |
FMS ( 0, 6, 11,10, 3, "Intel (unknown type) (Raptor Lake-P Q0)"); // ILPMDF* 20230214
|
3731 | |
FM ( 0, 6, 11,10, "Intel (unknown type) (Raptor Lake-P)"); // LX*; DPTF*; Coreboot*
|
|
3781 |
// Intel doc 743844 provides steppings 2 & 3, with names!
|
|
3782 |
// IPLMDF* 20230214 contradicts it, saying 2=Q0, but it's prone to cut&paste
|
|
3783 |
// errors, so adhering to the official docs.
|
|
3784 |
FMSQ( 0, 6, 11,10, 2, Ha, "Intel Core i*-13000 E-core (Raptor Lake-H/U/P J0)");
|
|
3785 |
FMSQ( 0, 6, 11,10, 2, Hc, "Intel Core i*-13000 P-core (Raptor Lake-H/U/P J0)");
|
|
3786 |
FMSQ( 0, 6, 11,10, 2, dc, "Intel Core i*-13000 (Raptor Lake-H/U/P J0)");
|
|
3787 |
FMS ( 0, 6, 11,10, 2, "Intel (unknown type) (Raptor Lake-H/U/P J0)");
|
|
3788 |
FMSQ( 0, 6, 11,10, 3, Ha, "Intel Core i*-13000 E-core (Raptor Lake-P Q0)");
|
|
3789 |
FMSQ( 0, 6, 11,10, 3, Hc, "Intel Core i*-13000 P-core (Raptor Lake-P Q0)");
|
|
3790 |
FMSQ( 0, 6, 11,10, 3, dc, "Intel Core i*-13000 (Raptor Lake-P Q0)");
|
|
3791 |
FMS ( 0, 6, 11,10, 3, "Intel (unknown type) (Raptor Lake-P Q0)");
|
|
3792 |
FM ( 0, 6, 11,10, "Intel (unknown type) (Raptor Lake-P)");
|
3732 | 3793 |
FM ( 0, 6, 11,13, "Intel (unknown type) (Lunar Lake)"); // LX*
|
3733 | |
FMS ( 0, 6, 11,14, 0, "Intel (unknown type) (Alder Lake-N A0)"); // Coreboot*, DPTF*
|
3734 | |
FM ( 0, 6, 11,14, "Intel (unknown type) (Alder Lake-N)"); // Coreboot*, LX*, DPTF*
|
|
3794 |
FMSQ( 0, 6, 11,14, 0, Ia, "Intel Core i*-N300 N-Series E-core (Alder Lake-N A0)");
|
|
3795 |
FMSQ( 0, 6, 11,14, 0, Ic, "Intel Core i*-N300 N-Series P-core (Alder Lake-N A0)"); // possibly no P-cores ever for this model
|
|
3796 |
FMSQ( 0, 6, 11,14, 0, Ha, "Intel N-Series E-core (Alder Lake-N A0)");
|
|
3797 |
FMSQ( 0, 6, 11,14, 0, Hc, "Intel N-Series P-core (Alder Lake-N A0)"); // possibly no P-cores ever for this model
|
|
3798 |
FMS ( 0, 6, 11,14, 0, "Intel N-Series (Alder Lake-N A0)");
|
|
3799 |
FMQ ( 0, 6, 11,14, Ia, "Intel Core i*-N300 N-Series E-core (Alder Lake-N)");
|
|
3800 |
FMQ ( 0, 6, 11,14, Ic, "Intel Core i*-N300 N-Series P-core (Alder Lake-N)"); // possibly no P-cores ever for this model
|
|
3801 |
FMQ ( 0, 6, 11,14, Ha, "Intel N-Series E-core (Alder Lake-N)");
|
|
3802 |
FMQ ( 0, 6, 11,14, Hc, "Intel N-Series P-core (Alder Lake-N)"); // possibly no P-cores ever for this model
|
|
3803 |
FM ( 0, 6, 11,14, "Intel N-Series (Alder Lake-N)");
|
|
3804 |
// Intel doc 743844 provides steppings 2 & 5, with names!
|
3735 | 3805 |
FMSQ( 0, 6, 11,15, 2, Ha, "Intel Core i*-13000 E-core (Raptor Lake-S/HX C0)");
|
3736 | 3806 |
FMSQ( 0, 6, 11,15, 2, Hc, "Intel Core i*-13000 P-core (Raptor Lake-S/HX C0)");
|
3737 | 3807 |
FMSQ( 0, 6, 11,15, 2, dc, "Intel Core i*-13000 (Raptor Lake-S/HX C0)");
|
3738 | 3808 |
FMS ( 0, 6, 11,15, 2, "Intel (unknown type) (Raptor Lake-S/HX C0)");
|
3739 | |
FMSQ( 0, 6, 11,15, 5, Ha, "Intel Core i*-13000 E-core (Raptor Lake-S/HX C0)");
|
3740 | |
FMSQ( 0, 6, 11,15, 5, Hc, "Intel Core i*-13000 P-core (Raptor Lake-S/HX C0)");
|
3741 | |
FMSQ( 0, 6, 11,15, 5, dc, "Intel Core i*-13000 (Raptor Lake-S/HX C0)");
|
3742 | |
FMS ( 0, 6, 11,15, 5, "Intel (unknown type) (Raptor Lake-S/HX C0)");
|
3743 | |
FMQ ( 0, 6, 11,15, Ha, "Intel Core i*-13000 E-core (Raptor Lake-S/H)");
|
3744 | |
FMQ ( 0, 6, 11,15, Hc, "Intel Core i*-13000 P-core (Raptor Lake-S/H)");
|
3745 | |
FMQ ( 0, 6, 11,15, dc, "Intel Core i*-13000 (Raptor Lake-S/H)");
|
3746 | |
FM ( 0, 6, 11,15, "Intel (unknown type) (Raptor Lake-S/H)");
|
|
3809 |
FMSQ( 0, 6, 11,15, 5, Ha, "Intel Core i*-13000 E-core (Raptor Lake-S/HX/P C0)");
|
|
3810 |
FMSQ( 0, 6, 11,15, 5, Hc, "Intel Core i*-13000 P-core (Raptor Lake-S/HX/P C0)");
|
|
3811 |
FMSQ( 0, 6, 11,15, 5, dc, "Intel Core i*-13000 (Raptor Lake-S/HX/P C0)");
|
|
3812 |
FMS ( 0, 6, 11,15, 5, "Intel (unknown type) (Raptor Lake-S/HX/P C0)");
|
|
3813 |
FMQ ( 0, 6, 11,15, Ha, "Intel Core i*-13000 E-core (Raptor Lake-S/HX/P)");
|
|
3814 |
FMQ ( 0, 6, 11,15, Hc, "Intel Core i*-13000 P-core (Raptor Lake-S/HX/P)");
|
|
3815 |
FMQ ( 0, 6, 11,15, dc, "Intel Core i*-13000 (Raptor Lake-S/HX/P)");
|
|
3816 |
FM ( 0, 6, 11,15, "Intel (unknown type) (Raptor Lake-S/HX/P)");
|
|
3817 |
FM ( 0, 6, 12, 6, "Intel (unknown type) (Arrow Lake)"); // LX*
|
3747 | 3818 |
FM ( 0, 6, 12,15, "Intel Xeon (unknown type) (Emerald Rapids)"); // MSR_CPUID_table*, LX*
|
3748 | 3819 |
FQ ( 0, 6, sX, "Intel Xeon (unknown model)");
|
3749 | 3820 |
FQ ( 0, 6, se, "Intel Xeon (unknown model)");
|
|
4729 | 4800 |
FMS (10,15, 7, 0, 0, "AMD Ryzen (Phoenix A0)");
|
4730 | 4801 |
FM (10,15, 7, 0, "AMD Ryzen (Phoenix)");
|
4731 | 4802 |
FMS (10,15, 7, 4, 0, "AMD Ryzen (Phoenix E0)"); // undocumented, but engr sample via instlatx64 from bakerlab.org (6220795)
|
|
4803 |
FMS (10,15, 7, 4, 1, "AMD Ryzen (Phoenix E1)"); // undocumented, but engr sample via from @BenchLeaks
|
4732 | 4804 |
FM (10,15, 7, 4, "AMD Ryzen (Phoenix)"); // undocumented, but engr sample via instlatx64 from bakerlab.org (6220795)
|
4733 | 4805 |
FMS (10,15, 7, 8, 0, "AMD Ryzen (Phoenix 2 A0)"); // Coreboot*
|
4734 | 4806 |
FM (10,15, 7, 8, "AMD Ryzen (Phoenix 2)"); // Coreboot*
|
4735 | 4807 |
FMS (10,15, 10, 0, 0, "AMD Ryzen (Bergamo A0)"); // undocumented, but (engr?) sample via instlatx64 from @ExecuFix
|
|
4808 |
FMS (10,15, 10, 0, 1, "AMD Ryzen (Bergamo A1)"); // undocumented, but (engr?) sample from @YuuKi_AnS
|
4736 | 4809 |
FM (10,15, 10, 0, "AMD Ryzen (Bergamo)"); // undocumented, but (engr?) sample via instlatx64 from @ExecuFix
|
4737 | 4810 |
FMS (10,15, 10, 1, 1, "AMD Ryzen (Bergamo B1)");
|
4738 | 4811 |
FM (10,15, 10, 1, "AMD Ryzen (Bergamo)");
|
|
5229 | 5302 |
#define GET_CoresPerComputeUnit_AMD(val_8000001e_ebx) \
|
5230 | 5303 |
(BIT_EXTRACT_LE((val_8000001e_ebx), 8, 16))
|
5231 | 5304 |
|
5232 | |
#define V2_TOPO_SMT 1
|
5233 | |
#define V2_TOPO_CORE 2
|
5234 | |
|
5235 | 5305 |
static void decode_mp_synth(code_stash_t* stash)
|
5236 | 5306 |
{
|
5237 | 5307 |
switch (stash->vendor) {
|
|
5247 | 5317 |
*/
|
5248 | 5318 |
if (stash->saw_1f) {
|
5249 | 5319 |
stash->mp.method = "Intel leaf 0x1f";
|
|
5320 |
unsigned int last_count = 1;
|
5250 | 5321 |
unsigned int try;
|
5251 | 5322 |
for (try = 0; try < LENGTH(stash->val_1f_ecx); try++) {
|
5252 | |
if (GET_V2_TOPO_LEVEL(stash->val_1f_ecx[try]) == V2_TOPO_SMT) {
|
5253 | |
stash->mp.hyperthreads
|
5254 | |
= GET_V2_TOPO_PROCESSORS(stash->val_1f_ebx[try]);
|
5255 | |
} else if (GET_V2_TOPO_LEVEL(stash->val_1f_ecx[try]) == V2_TOPO_CORE) {
|
5256 | |
stash->mp.cores = GET_V2_TOPO_PROCESSORS(stash->val_1f_ebx[try]);
|
|
5323 |
unsigned int level = GET_V2_TOPO_LEVEL(stash->val_1f_ecx[try]);
|
|
5324 |
if (level < LENGTH(v2TopoToCotopo)) {
|
|
5325 |
unsigned ct = v2TopoToCotopo[level];
|
|
5326 |
if (ct != Invalid) {
|
|
5327 |
unsigned int count
|
|
5328 |
= GET_V2_TOPO_PROCESSORS(stash->val_1f_ebx[try]);
|
|
5329 |
stash->mp.count[ct] = count / last_count;
|
|
5330 |
last_count = count;
|
|
5331 |
}
|
5257 | 5332 |
}
|
5258 | 5333 |
}
|
5259 | 5334 |
} else if (stash->saw_b) {
|
|
5263 | 5338 |
if (ht == 0) {
|
5264 | 5339 |
ht = 1;
|
5265 | 5340 |
}
|
5266 | |
stash->mp.cores = tc / ht;
|
5267 | |
stash->mp.hyperthreads = ht;
|
|
5341 |
stash->mp.count[Core] = tc / ht;
|
|
5342 |
stash->mp.count[Smt] = ht;
|
5268 | 5343 |
} else if (stash->saw_4) {
|
5269 | 5344 |
unsigned int tc = GET_LogicalProcessorCount(stash->val_1_ebx);
|
5270 | 5345 |
unsigned int c;
|
|
5276 | 5351 |
c = tc / 2;
|
5277 | 5352 |
stash->mp.method = "Intel leaf 1/4 (zero fallback)";
|
5278 | 5353 |
}
|
5279 | |
stash->mp.cores = c;
|
5280 | |
stash->mp.hyperthreads = tc / c;
|
|
5354 |
stash->mp.count[Core] = c;
|
|
5355 |
stash->mp.count[Smt] = tc / c;
|
5281 | 5356 |
} else {
|
5282 | 5357 |
stash->mp.method = "Intel leaf 1";
|
5283 | |
stash->mp.cores = 1;
|
|
5358 |
stash->mp.count[Core] = 1;
|
5284 | 5359 |
if (IS_HTT(stash->val_1_edx)) {
|
5285 | 5360 |
unsigned int tc = GET_LogicalProcessorCount(stash->val_1_ebx);
|
5286 | |
stash->mp.hyperthreads = (tc >= 2 ? tc : 2);
|
|
5361 |
stash->mp.count[Smt] = (tc >= 2 ? tc : 2);
|
5287 | 5362 |
} else {
|
5288 | |
stash->mp.hyperthreads = 1;
|
|
5363 |
stash->mp.count[Smt] = 1;
|
5289 | 5364 |
}
|
5290 | 5365 |
}
|
5291 | 5366 |
break;
|
5292 | 5367 |
case VENDOR_AMD:
|
5293 | 5368 |
case VENDOR_HYGON:
|
5294 | |
/*
|
5295 | |
** Logic from:
|
5296 | |
** AMD CPUID Specification (25481 Rev. 2.16),
|
5297 | |
** 3. LogicalProcessorCount, CmpLegacy, HTT, and NC
|
5298 | |
** AMD CPUID Specification (25481 Rev. 2.28),
|
5299 | |
** 3. Multiple Core Calculation
|
5300 | |
*/
|
5301 | |
if (IS_HTT(stash->val_1_edx)) {
|
5302 | |
unsigned int tc = GET_LogicalProcessorCount(stash->val_1_ebx);
|
5303 | |
unsigned int c;
|
5304 | |
if (GET_ApicIdCoreIdSize(stash->val_80000008_ecx) != 0) {
|
5305 | |
unsigned int size = GET_ApicIdCoreIdSize(stash->val_80000008_ecx);
|
5306 | |
unsigned int mask = (1 << size) - 1;
|
5307 | |
c = (GET_NC_AMD(stash->val_80000008_ecx) & mask) + 1;
|
5308 | |
} else {
|
5309 | |
c = GET_NC_AMD(stash->val_80000008_ecx) + 1;
|
|
5369 |
if (stash->saw_b) {
|
|
5370 |
/*
|
|
5371 |
** Logic by analogy to Intel
|
|
5372 |
*/
|
|
5373 |
unsigned int ht = GET_X2APIC_PROCESSORS(stash->val_b_ebx[0]);
|
|
5374 |
unsigned int tc = GET_X2APIC_PROCESSORS(stash->val_b_ebx[1]);
|
|
5375 |
stash->mp.method = (stash->vendor == VENDOR_AMD ? "AMD leaf 0xb"
|
|
5376 |
: "Hygon leaf 0xb");
|
|
5377 |
if (ht == 0) {
|
|
5378 |
ht = 1;
|
5310 | 5379 |
}
|
5311 | |
if ((tc == c) == IS_CmpLegacy(stash->val_80000001_ecx)) {
|
5312 | |
stash->mp.method = (stash->vendor == VENDOR_AMD ? "AMD"
|
5313 | |
: "Hygon");
|
5314 | |
if (c > 1) {
|
5315 | |
stash->mp.cores = c;
|
5316 | |
stash->mp.hyperthreads = tc / c;
|
|
5380 |
stash->mp.count[Core] = tc / ht;
|
|
5381 |
stash->mp.count[Smt] = ht;
|
|
5382 |
} else if (IS_HTT(stash->val_1_edx)) {
|
|
5383 |
/*
|
|
5384 |
** Logic from:
|
|
5385 |
** AMD CPUID Specification (25481 Rev. 2.16),
|
|
5386 |
** 3. LogicalProcessorCount, CmpLegacy, HTT, and NC
|
|
5387 |
** AMD CPUID Specification (25481 Rev. 2.28),
|
|
5388 |
** 3. Multiple Core Calculation
|
|
5389 |
**
|
|
5390 |
** For Families 10h-16h, the CU (CMT "compute unit") logic was a
|
|
5391 |
** logical extension.
|
|
5392 |
**
|
|
5393 |
** For Families 17h and later, terminology changed to reflect that
|
|
5394 |
** the Family 10h-16h cores had been sharing resources significantly:
|
|
5395 |
** Family 10h-16h => Family 17h
|
|
5396 |
** ----------------------------
|
|
5397 |
** CU => core
|
|
5398 |
** core => thread
|
|
5399 |
** And leaf 0x8000001e/ebx is used for smt_count, because 1/ebx is
|
|
5400 |
** unreliable.
|
|
5401 |
*/
|
|
5402 |
unsigned int size = (GET_ApicIdCoreIdSize(stash->val_80000008_ecx) != 0
|
|
5403 |
? GET_ApicIdCoreIdSize(stash->val_80000008_ecx)
|
|
5404 |
: 32);
|
|
5405 |
unsigned int mask = RIGHTMASK(size);
|
|
5406 |
unsigned int core_count
|
|
5407 |
= (GET_NC_AMD(stash->val_80000008_ecx) & mask) + 1;
|
|
5408 |
unsigned int total_count = GET_LogicalProcessorCount(stash->val_1_ebx);
|
|
5409 |
unsigned int smt_count = total_count / core_count;
|
|
5410 |
unsigned int cu_count = 1;
|
|
5411 |
if (GET_CoresPerComputeUnit_AMD(stash->val_8000001e_ebx) != 0) {
|
|
5412 |
if (Synth_Family(stash->val_80000001_eax) > 0x16) {
|
|
5413 |
unsigned int threads_per_core
|
|
5414 |
= GET_CoresPerComputeUnit_AMD(stash->val_8000001e_ebx) + 1;
|
|
5415 |
smt_count = threads_per_core;
|
|
5416 |
core_count /= threads_per_core;
|
5317 | 5417 |
} else {
|
5318 | |
stash->mp.cores = 1;
|
5319 | |
stash->mp.hyperthreads = (tc >= 2 ? tc : 2);
|
|
5418 |
unsigned int cores_per_cu
|
|
5419 |
= GET_CoresPerComputeUnit_AMD(stash->val_8000001e_ebx) + 1;
|
|
5420 |
cu_count = (core_count / cores_per_cu);
|
|
5421 |
core_count = cores_per_cu;
|
5320 | 5422 |
}
|
5321 | |
} else {
|
5322 | |
/*
|
5323 | |
** Rev 2.28 leaves out mention that this case is nonsensical, but
|
5324 | |
** I'm leaving it in here as an "unknown" case.
|
5325 | |
*/
|
5326 | 5423 |
}
|
|
5424 |
stash->mp.method = (stash->vendor == VENDOR_AMD
|
|
5425 |
? "AMD leaf 1/0x8000008"
|
|
5426 |
: "Hygon leaf 1/0x80000008");
|
|
5427 |
stash->mp.count[Core] = core_count;
|
|
5428 |
stash->mp.count[Smt] = smt_count;
|
|
5429 |
stash->mp.count[Cu] = cu_count;
|
5327 | 5430 |
} else {
|
5328 | |
stash->mp.method = (stash->vendor == VENDOR_AMD ? "AMD" : "Hygon");
|
5329 | |
stash->mp.cores = 1;
|
5330 | |
stash->mp.hyperthreads = 1;
|
|
5431 |
stash->mp.method = (stash->vendor == VENDOR_AMD ? "AMD leaf 1"
|
|
5432 |
: "Hygon leaf 1");
|
|
5433 |
stash->mp.count[Core] = 1;
|
|
5434 |
stash->mp.count[Smt] = 1;
|
5331 | 5435 |
}
|
5332 | 5436 |
break;
|
5333 | 5437 |
default:
|
5334 | 5438 |
if (!IS_HTT(stash->val_1_edx)) {
|
5335 | 5439 |
stash->mp.method = "Generic leaf 1 no multi-threading";
|
5336 | |
stash->mp.cores = 1;
|
5337 | |
stash->mp.hyperthreads = 1;
|
|
5440 |
stash->mp.count[Core] = 1;
|
|
5441 |
stash->mp.count[Smt] = 1;
|
5338 | 5442 |
}
|
5339 | 5443 |
break;
|
5340 | 5444 |
}
|
|
5342 | 5446 |
|
5343 | 5447 |
static void print_mp_synth(const struct mp* mp)
|
5344 | 5448 |
{
|
|
5449 |
static ccstring prefix[NumCotopos] = { "hyper-threaded (t",
|
|
5450 |
"multi-core (c",
|
|
5451 |
"multi-compute-unit (cu",
|
|
5452 |
"multi-module (m",
|
|
5453 |
"multi-tile (t",
|
|
5454 |
"multi-die (d",
|
|
5455 |
"multi-die-group (dg",
|
|
5456 |
"multi-package (p" };
|
|
5457 |
|
5345 | 5458 |
printf(" (multi-processing synth) = ");
|
5346 | 5459 |
if (mp->method == NULL) {
|
5347 | 5460 |
printf("?");
|
5348 | |
} else if (mp->cores > 1) {
|
5349 | |
if (mp->hyperthreads > 1) {
|
5350 | |
printf("multi-core (c=%u), hyper-threaded (t=%u)",
|
5351 | |
mp->cores, mp->hyperthreads);
|
5352 | |
} else {
|
5353 | |
printf("multi-core (c=%u)", mp->cores);
|
|
5461 |
} else {
|
|
5462 |
boolean first = TRUE;
|
|
5463 |
for (unsigned int ct = NumCotopos-1;; ct--) {
|
|
5464 |
if (mp->count[ct] > 1) {
|
|
5465 |
if (first) {
|
|
5466 |
first = FALSE;
|
|
5467 |
} else {
|
|
5468 |
printf(", ");
|
|
5469 |
}
|
|
5470 |
printf("%s=%u)", prefix[ct], mp->count[ct]);
|
|
5471 |
}
|
|
5472 |
if (ct == 0) break;
|
5354 | 5473 |
}
|
5355 | |
} else if (mp->hyperthreads > 1) {
|
5356 | |
printf("hyper-threaded (t=%u)", mp->hyperthreads);
|
5357 | |
} else {
|
5358 | |
printf("none");
|
|
5474 |
if (first) {
|
|
5475 |
printf("none");
|
|
5476 |
}
|
5359 | 5477 |
}
|
5360 | 5478 |
printf("\n");
|
5361 | 5479 |
|
|
5407 | 5525 |
|
5408 | 5526 |
static void print_apic_synth (code_stash_t* stash)
|
5409 | 5527 |
{
|
5410 | |
unsigned int smt_width = 0;
|
5411 | |
unsigned int core_width = 0;
|
5412 | |
unsigned int cu_width = 0;
|
5413 | |
|
|
5528 |
typedef struct {
|
|
5529 |
ccstring abbrev;
|
|
5530 |
boolean alwaysShowWidth;
|
|
5531 |
boolean alwaysShowId;
|
|
5532 |
} CotopoDisplay;
|
|
5533 |
static CotopoDisplay dsp[NumCotopos] = { { "SMT", TRUE, TRUE },
|
|
5534 |
{ "CORE", TRUE, TRUE },
|
|
5535 |
{ "CU", FALSE, FALSE },
|
|
5536 |
{ "MOD", FALSE, FALSE },
|
|
5537 |
{ "TILE", FALSE, FALSE },
|
|
5538 |
{ "DIE", FALSE, FALSE },
|
|
5539 |
{ "DIEGRP", FALSE, FALSE },
|
|
5540 |
{ "PKG", FALSE, TRUE } };
|
|
5541 |
unsigned int widths[NumCotopos] = { 0, 0, 0, 0, 0, 0, 0, 0 };
|
|
5542 |
unsigned int offsets[NumCotopos] = { 0, 0, 0, 0, 0, 0, 0, 0 };
|
|
5543 |
unsigned int tails[NumCotopos] = { 0, 0, 0, 0, 0, 0, 0, 0 };
|
|
5544 |
|
5414 | 5545 |
switch (stash->vendor) {
|
5415 | 5546 |
case VENDOR_INTEL:
|
5416 | 5547 |
/*
|
|
5423 | 5554 |
** Extension to the 0x1f leaf was obvious.
|
5424 | 5555 |
*/
|
5425 | 5556 |
if (stash->saw_1f) {
|
|
5557 |
unsigned int last_width = 0;
|
5426 | 5558 |
unsigned int try;
|
5427 | 5559 |
for (try = 0; try < LENGTH(stash->val_1f_ecx); try++) {
|
5428 | 5560 |
unsigned int level = GET_V2_TOPO_LEVEL(stash->val_1f_ecx[try]);
|
5429 | |
if (level == V2_TOPO_SMT) {
|
5430 | |
smt_width = GET_V2_TOPO_WIDTH(stash->val_1f_eax[try]);
|
5431 | |
} else if (level == V2_TOPO_CORE) {
|
5432 | |
core_width = GET_V2_TOPO_WIDTH(stash->val_1f_eax[try]);
|
|
5561 |
unsigned int width = GET_V2_TOPO_WIDTH(stash->val_1f_eax[try]);
|
|
5562 |
if (level < LENGTH(v2TopoToCotopo)) {
|
|
5563 |
unsigned ct = v2TopoToCotopo[level];
|
|
5564 |
if (ct != Invalid) {
|
|
5565 |
widths[ct] = width - last_width;
|
|
5566 |
}
|
5433 | 5567 |
}
|
|
5568 |
last_width = width;
|
5434 | 5569 |
}
|
5435 | 5570 |
} else if (stash->saw_b) {
|
5436 | |
smt_width = GET_X2APIC_WIDTH(stash->val_b_eax[0]);
|
5437 | |
core_width = GET_X2APIC_WIDTH(stash->val_b_eax[1]);
|
|
5571 |
widths[Smt] = GET_X2APIC_WIDTH(stash->val_b_eax[0]);
|
|
5572 |
widths[Core] = GET_X2APIC_WIDTH(stash->val_b_eax[1]) - widths[Smt];
|
5438 | 5573 |
} else if (stash->saw_4 && (stash->val_4_eax & 0x1f) != 0) {
|
5439 | 5574 |
unsigned int core_count = GET_NC_INTEL(stash->val_4_eax) + 1;
|
5440 | 5575 |
unsigned int smt_count = (GET_LogicalProcessorCount(stash->val_1_ebx)
|
5441 | 5576 |
/ core_count);
|
5442 | |
smt_width = bits_needed(smt_count);
|
5443 | |
core_width = bits_needed(core_count);
|
|
5577 |
widths[Smt] = bits_needed(smt_count);
|
|
5578 |
widths[Core] = bits_needed(core_count);
|
5444 | 5579 |
} else {
|
5445 | 5580 |
return;
|
5446 | 5581 |
}
|
5447 | 5582 |
break;
|
5448 | 5583 |
case VENDOR_AMD:
|
|
5584 |
case VENDOR_HYGON:
|
5449 | 5585 |
/*
|
5450 | 5586 |
** Logic deduced by analogy: As Intel's decode_mp_synth code is to AMD's
|
5451 | 5587 |
** decode_mp_synth code, so is Intel's APIC synth code to this.
|
|
5454 | 5590 |
** logical extension.
|
5455 | 5591 |
**
|
5456 | 5592 |
** For Families 17h and later, terminology changed to reflect that
|
5457 | |
** the Family 10h-16h cores had been sharing resources significantly,
|
5458 | |
** similarly to (but less drastically than) SMT threads:
|
|
5593 |
** the Family 10h-16h cores had been sharing resources significantly:
|
5459 | 5594 |
** Family 10h-16h => Family 17h
|
5460 | 5595 |
** ----------------------------
|
5461 | 5596 |
** CU => core
|
|
5463 | 5598 |
** And leaf 0x8000001e/ebx is used for smt_count, because 1/ebx is
|
5464 | 5599 |
** unreliable.
|
5465 | 5600 |
*/
|
5466 | |
if (IS_HTT(stash->val_1_edx)
|
5467 | |
&& GET_ApicIdCoreIdSize(stash->val_80000008_ecx) != 0) {
|
|
5601 |
if (stash->saw_b) {
|
|
5602 |
widths[Smt] = GET_X2APIC_WIDTH(stash->val_b_eax[0]);
|
|
5603 |
widths[Core] = GET_X2APIC_WIDTH(stash->val_b_eax[1]) - widths[Smt];
|
|
5604 |
} else if (IS_HTT(stash->val_1_edx)
|
|
5605 |
&& GET_ApicIdCoreIdSize(stash->val_80000008_ecx) != 0) {
|
5468 | 5606 |
unsigned int size = GET_ApicIdCoreIdSize(stash->val_80000008_ecx);
|
5469 | |
unsigned int mask = (1 << size) - 1;
|
5470 | |
unsigned int core_count = ((GET_NC_AMD(stash->val_80000008_ecx) & mask)
|
5471 | |
+ 1);
|
5472 | |
unsigned int smt_count = (GET_LogicalProcessorCount(stash->val_1_ebx)
|
5473 | |
/ core_count);
|
5474 | |
unsigned int cu_count = 1;
|
|
5607 |
unsigned int mask = RIGHTMASK(size);
|
|
5608 |
unsigned int core_count
|
|
5609 |
= (GET_NC_AMD(stash->val_80000008_ecx) & mask) + 1;
|
|
5610 |
unsigned int total_count = GET_LogicalProcessorCount(stash->val_1_ebx);
|
|
5611 |
unsigned int smt_count = total_count / core_count;
|
|
5612 |
unsigned int cu_count = 1;
|
5475 | 5613 |
if (GET_CoresPerComputeUnit_AMD(stash->val_8000001e_ebx) != 0) {
|
5476 | 5614 |
if (Synth_Family(stash->val_80000001_eax) > 0x16) {
|
5477 | 5615 |
unsigned int threads_per_core
|
|
5485 | 5623 |
core_count = cores_per_cu;
|
5486 | 5624 |
}
|
5487 | 5625 |
}
|
5488 | |
smt_width = bits_needed(smt_count);
|
5489 | |
core_width = bits_needed(core_count);
|
5490 | |
cu_width = bits_needed(cu_count);
|
|
5626 |
widths[Smt] = bits_needed(smt_count);
|
|
5627 |
widths[Core] = bits_needed(core_count);
|
|
5628 |
widths[Cu] = bits_needed(cu_count);
|
5491 | 5629 |
} else {
|
5492 | 5630 |
return;
|
5493 | 5631 |
}
|
|
5496 | 5634 |
return;
|
5497 | 5635 |
}
|
5498 | 5636 |
|
5499 | |
// Possibly this should be expanded with Intel leaf 1f's module, tile, and
|
5500 | |
// die levels. They could be made into hidden architectural levels unless
|
5501 | |
// actually present, much like the CU level.
|
5502 | |
|
5503 | 5637 |
printf(" (APIC widths synth):");
|
5504 | |
if (cu_width != 0) {
|
5505 | |
printf(" CU_width=%u", cu_width);
|
|
5638 |
for (unsigned int ct = NumCotopos-1;; ct--) {
|
|
5639 |
if (dsp[ct].alwaysShowWidth || widths[ct] != 0) {
|
|
5640 |
printf(" %s_width=%u", dsp[ct].abbrev, widths[ct]);
|
|
5641 |
}
|
|
5642 |
if (ct == 0) break;
|
5506 | 5643 |
}
|
5507 | |
printf(" CORE_width=%u", core_width);
|
5508 | |
printf(" SMT_width=%u", smt_width);
|
5509 | 5644 |
printf("\n");
|
5510 | 5645 |
|
5511 | |
unsigned int smt_off = 24;
|
5512 | |
unsigned int smt_tail = smt_off + smt_width;
|
5513 | |
unsigned int core_off = smt_tail;
|
5514 | |
unsigned int core_tail = core_off + core_width;
|
5515 | |
unsigned int cu_off = core_tail;
|
5516 | |
unsigned int cu_tail = cu_off + cu_width;
|
5517 | |
unsigned int pkg_off = cu_tail;
|
5518 | |
unsigned int pkg_tail = 32;
|
|
5646 |
// Compute the offsets & tails so that the bit fields can be walked in
|
|
5647 |
// reverse order, outermost:Pkg to innermost:Smt.
|
|
5648 |
{
|
|
5649 |
unsigned int offset = 0;
|
|
5650 |
for (unsigned int ct = 0; ct < NumCotopos; ct++) {
|
|
5651 |
offsets[ct] = offset;
|
|
5652 |
tails[ct] = offset + widths[ct];
|
|
5653 |
offset = tails[ct];
|
|
5654 |
}
|
|
5655 |
// The highest level (Pkg) always is all of the remaining bits
|
|
5656 |
tails[NumCotopos-1] = 32;
|
|
5657 |
}
|
|
5658 |
|
|
5659 |
unsigned int apic_id;
|
|
5660 |
if (stash->saw_8000001e && Synth_Family(stash->val_1_eax) != 0x15) {
|
|
5661 |
// The 0x8000001e/eax extended APIC ID appears to have unreliable values
|
|
5662 |
// in the Piledriver..Excavator timeframe.
|
|
5663 |
apic_id = stash->val_8000001e_eax;
|
|
5664 |
} else if (stash->saw_1f) {
|
|
5665 |
apic_id = stash->val_1f_edx;
|
|
5666 |
} else if (stash->saw_b) {
|
|
5667 |
apic_id = stash->val_b_edx;
|
|
5668 |
} else {
|
|
5669 |
apic_id = BIT_EXTRACT_LE(stash->val_1_ebx, 24, 32);
|
|
5670 |
}
|
5519 | 5671 |
|
5520 | 5672 |
printf(" (APIC synth):");
|
5521 | |
printf(" PKG_ID=%d", (pkg_off < pkg_tail
|
5522 | |
? BIT_EXTRACT_LE(stash->val_1_ebx, pkg_off, pkg_tail)
|
5523 | |
: 0));
|
5524 | |
if (cu_width != 0) {
|
5525 | |
printf(" CU_ID=%d", BIT_EXTRACT_LE(stash->val_1_ebx, cu_off, cu_tail));
|
|
5673 |
for (unsigned int ct = NumCotopos-1;; ct--) {
|
|
5674 |
if (dsp[ct].alwaysShowId || widths[ct] != 0) {
|
|
5675 |
printf(" %s_ID=%u",
|
|
5676 |
dsp[ct].abbrev,
|
|
5677 |
BIT_EXTRACT_LE(apic_id, offsets[ct], tails[ct]));
|
|
5678 |
}
|
|
5679 |
if (ct == 0) break;
|
5526 | 5680 |
}
|
5527 | |
printf(" CORE_ID=%d", BIT_EXTRACT_LE(stash->val_1_ebx, core_off, core_tail));
|
5528 | |
printf(" SMT_ID=%d", BIT_EXTRACT_LE(stash->val_1_ebx, smt_off, smt_tail));
|
5529 | 5681 |
printf("\n");
|
5530 | 5682 |
}
|
5531 | 5683 |
|
|
6306 | 6458 |
static named_item names[]
|
6307 | 6459 |
= { { "AVX-VNNI-INT8 instructions" , 4, 4, bools },
|
6308 | 6460 |
{ "AVX-NE-CONVERT instructions" , 5, 5, bools },
|
|
6461 |
{ "AVX-COMPLEX instructions" , 8, 8, bools },
|
6309 | 6462 |
{ "PREFETCHIT0, PREFETCHIT1 instructions" , 14, 14, bools },
|
6310 | 6463 |
{ "CET_SSS: shadow stacks w/o page faults" , 18, 18, bools },
|
6311 | 6464 |
};
|
|
6323 | 6476 |
{ "DDPD_U: data dep prefetcher disable" , 3, 3, bools },
|
6324 | 6477 |
{ "BHI_CTRL: IBP BHB-focused disable" , 4, 4, bools },
|
6325 | 6478 |
{ "MCDT_NO: MCDT mitigation not needed" , 5, 5, bools },
|
|
6479 |
{ "UC-lock disable" , 6, 6, bools },
|
6326 | 6480 |
};
|
6327 | 6481 |
print_names(value, names, LENGTH(names),
|
6328 | 6482 |
/* max_len => */ 40);
|
|
6395 | 6549 |
print_b_1f_eax(unsigned int value)
|
6396 | 6550 |
{
|
6397 | 6551 |
static named_item names[]
|
6398 | |
= { { "bit width of level" , 0, 4, NIL_IMAGES },
|
|
6552 |
= { { "bit width of level & previous levels" , 0, 4, NIL_IMAGES },
|
6399 | 6553 |
};
|
6400 | 6554 |
|
6401 | 6555 |
print_names(value, names, LENGTH(names),
|
|
6416 | 6570 |
static void
|
6417 | 6571 |
print_b_1f_ecx(unsigned int value)
|
6418 | 6572 |
{
|
|
6573 |
// If more levels are added here, be sure to check:
|
|
6574 |
// V2_TOPO_NUM
|
|
6575 |
// val_1f_{eax,ebx,ecx} (in code_stash_t)
|
|
6576 |
// NIL_STASH
|
|
6577 |
// v2TopotoCotopo
|
|
6578 |
// Cotopo
|
6419 | 6579 |
static ccstring level_type[1<<8] = { "invalid (0)",
|
6420 | 6580 |
"thread (1)",
|
6421 | 6581 |
"core (2)",
|
6422 | 6582 |
"module (3)",
|
6423 | 6583 |
"tile (4)",
|
6424 | |
"die (5)" };
|
|
6584 |
"die (5)",
|
|
6585 |
"die group (6)" };
|
6425 | 6586 |
|
6426 | 6587 |
static named_item names[]
|
6427 | 6588 |
= { { "level number" , 0, 7, NIL_IMAGES },
|
|
6715 | 6876 |
static named_item names[]
|
6716 | 6877 |
= { { "infrequent updates of COS" , 1, 1, bools },
|
6717 | 6878 |
{ "code and data prioritization supported" , 2, 2, bools },
|
|
6879 |
{ "non-contiguous 1s value supported" , 3, 3, bools },
|
6718 | 6880 |
};
|
6719 | 6881 |
|
6720 | 6882 |
print_names(value, names, LENGTH(names),
|
|
6764 | 6926 |
{ "SGX ENCLV E*VIRTCHILD, ESETCONTEXT" , 5, 5, bools },
|
6765 | 6927 |
{ "SGX ENCLS ETRACKC, ERDINFO, ELDBC, ELDUC", 6, 6, bools },
|
6766 | 6928 |
{ "SGX ENCLU EVERIFYREPORT2" , 7, 7, bools },
|
|
6929 |
{ "SGX ENCLS EUPDATESVN" , 10, 10, bools },
|
6767 | 6930 |
{ "SGX ENCLU EDECCSSA" , 11, 11, bools },
|
6768 | 6931 |
};
|
6769 | 6932 |
|
|
7215 | 7378 |
= { { "mispredict bit supported" , 0, 0, bools },
|
7216 | 7379 |
{ "timed LBRs supported" , 1, 1, bools },
|
7217 | 7380 |
{ "branch type field supported" , 2, 2, bools },
|
|
7381 |
{ "event logging supported bitmap" , 16, 19, NIL_IMAGES },
|
7218 | 7382 |
};
|
7219 | 7383 |
|
7220 | 7384 |
print_names(value, names, LENGTH(names),
|
|
7280 | 7444 |
|
7281 | 7445 |
print_names(value, names, LENGTH(names),
|
7282 | 7446 |
/* max_len => */ 0);
|
|
7447 |
}
|
|
7448 |
|
|
7449 |
static void
|
|
7450 |
print_23_0_ebx(unsigned int value)
|
|
7451 |
{
|
|
7452 |
static named_item names[]
|
|
7453 |
= { { "IA32_PERFEVTSELx UnitMask2 supported" , 0, 0, bools },
|
|
7454 |
{ "IA32_PERFEVTSELx Z bit supported" , 1, 1, bools },
|
|
7455 |
};
|
|
7456 |
|
|
7457 |
print_names(value, names, LENGTH(names),
|
|
7458 |
/* max_len => */ 36);
|
7283 | 7459 |
}
|
7284 | 7460 |
|
7285 | 7461 |
static void
|
|
7573 | 7749 |
{ "use synced timeline" , 15, 15, bools },
|
7574 | 7750 |
{ "use direct local flush entire" , 17, 17, bools },
|
7575 | 7751 |
{ "no non-architectural core sharing" , 18, 18, bools },
|
|
7752 |
{ "use hypercalls for MMIO config space I/O", 21, 21, bools },
|
7576 | 7753 |
};
|
7577 | 7754 |
|
7578 | 7755 |
print_names(value, names, LENGTH(names),
|
|
8703 | 8880 |
{ "INVLPGB/TLBSYNC hyperv interc enable" , 24, 24, bools },
|
8704 | 8881 |
{ "VNMI: NMI virtualization" , 25, 25, bools },
|
8705 | 8882 |
{ "IBS virtualization" , 26, 26, bools },
|
|
8883 |
{ "extended LVT offset fault change" , 27, 27, bools },
|
8706 | 8884 |
{ "guest SVME addr check" , 28, 28, bools }, // LX*, Qemu*
|
8707 | 8885 |
};
|
8708 | 8886 |
|
|
9065 | 9243 |
{
|
9066 | 9244 |
static named_item names[]
|
9067 | 9245 |
= { { "no nested data-breakpoints" , 0, 0, bools },
|
|
9246 |
{ "FsGsKernelGsBaseNonSerializing" , 1, 1, bools },
|
9068 | 9247 |
{ "LFENCE always serializing" , 2, 2, bools },
|
9069 | 9248 |
{ "SMM paging configuration lock support" , 3, 3, bools },
|
9070 | 9249 |
{ "null selector clears base" , 6, 6, bools },
|
9071 | 9250 |
{ "upper address ignore support" , 7, 7, bools },
|
9072 | 9251 |
{ "automatic IBRS" , 8, 8, bools },
|
9073 | 9252 |
{ "SMM_CTL MSR not supported" , 9, 9, bools },
|
|
9253 |
{ "FSRS: fast short REP STOSB support" , 10, 10, bools },
|
|
9254 |
{ "FSRC: fast short REP CMPSB support" , 11, 11, bools },
|
9074 | 9255 |
{ "prefetch control MSR support" , 13, 13, bools },
|
9075 | 9256 |
{ "CPUID disable for non-privileged" , 17, 17, bools },
|
|
9257 |
{ "enhanced predictive store forwarding" , 18, 18, bools },
|
9076 | 9258 |
};
|
9077 | 9259 |
|
9078 | 9260 |
print_names(value, names, LENGTH(names),
|
|
9111 | 9293 |
= { { "number of core perf ctrs" , 0, 3, NIL_IMAGES },
|
9112 | 9294 |
{ "number of LBR stack entries" , 4, 9, NIL_IMAGES },
|
9113 | 9295 |
{ "number of avail Northbridge perf ctrs" , 10, 15, NIL_IMAGES },
|
|
9296 |
{ "number of available UMC PMCs" , 16, 21, NIL_IMAGES },
|
9114 | 9297 |
};
|
9115 | 9298 |
|
9116 | 9299 |
print_names(value, names, LENGTH(names),
|
|
9156 | 9339 |
static void
|
9157 | 9340 |
print_80000026_1_ebx(unsigned int value)
|
9158 | 9341 |
{
|
|
9342 |
// These strings are from 55901 for Raphael. Is it possible they will differ
|
|
9343 |
// on other uarch's?
|
|
9344 |
static ccstring native_model[1<<4] = { "Zen4 (0)" };
|
|
9345 |
static ccstring core_type[1<<4] = { "performance (0)",
|
|
9346 |
"efficiency (1)" };
|
|
9347 |
|
9159 | 9348 |
static named_item names[]
|
9160 | 9349 |
= { { "number of logical processors at level" , 0, 15, NIL_IMAGES },
|
9161 | 9350 |
{ "power efficiency ranking" , 16, 23, NIL_IMAGES },
|
9162 | |
{ "native mode ID" , 24, 27, NIL_IMAGES },
|
9163 | |
{ "core type" , 28, 31, NIL_IMAGES },
|
|
9351 |
{ "native model ID" , 24, 27, native_model },
|
|
9352 |
{ "core type" , 28, 31, core_type },
|
9164 | 9353 |
};
|
9165 | 9354 |
|
9166 | 9355 |
print_names(value, names, LENGTH(names),
|
|
9654 | 9843 |
stash->val_4_eax = words[WORD_EAX];
|
9655 | 9844 |
}
|
9656 | 9845 |
} else if (reg == 0xb) {
|
9657 | |
stash->saw_b = TRUE;
|
|
9846 |
if (words[WORD_EAX] != 0
|
|
9847 |
|| words[WORD_EBX] != 0
|
|
9848 |
|| words[WORD_ECX] != 0
|
|
9849 |
|| words[WORD_EDX] != 0) {
|
|
9850 |
// If this returns all 0's, it's an unsupported leaf, and not even
|
|
9851 |
// the extended APIC ID should be used. AMD is particularly prone
|
|
9852 |
// to this.
|
|
9853 |
stash->saw_b = TRUE;
|
|
9854 |
}
|
|
9855 |
if (try == 0) {
|
|
9856 |
stash->val_b_edx = words[WORD_EDX];
|
|
9857 |
}
|
9658 | 9858 |
if (try < LENGTH(stash->val_b_eax)) {
|
9659 | 9859 |
stash->val_b_eax[try] = words[WORD_EAX];
|
9660 | 9860 |
}
|
|
9675 | 9875 |
}
|
9676 | 9876 |
} else if (reg == 0x1f) {
|
9677 | 9877 |
stash->saw_1f = TRUE;
|
|
9878 |
if (try == 0) {
|
|
9879 |
stash->val_1f_edx = words[WORD_EDX];
|
|
9880 |
}
|
9678 | 9881 |
if (try < LENGTH(stash->val_1f_eax)) {
|
9679 | 9882 |
stash->val_1f_eax[try] = words[WORD_EAX];
|
9680 | 9883 |
}
|
|
9700 | 9903 |
} else if (reg == 0x80000008) {
|
9701 | 9904 |
stash->val_80000008_ecx = words[WORD_ECX];
|
9702 | 9905 |
} else if (reg == 0x8000001e) {
|
|
9906 |
stash->saw_8000001e = TRUE;
|
|
9907 |
stash->val_8000001e_eax = words[WORD_EAX];
|
9703 | 9908 |
stash->val_8000001e_ebx = words[WORD_EBX];
|
9704 | |
} else if (reg == 0x80860003) {
|
|
9909 |
} else if (reg == 0x80860003) {
|
9705 | 9910 |
memcpy(&stash->transmeta_info[0], words,
|
9706 | 9911 |
sizeof(unsigned int)*WORD_NUM);
|
9707 | 9912 |
} else if (reg == 0x80860004) {
|
|
10058 | 10263 |
} else if (reg == 0x23) {
|
10059 | 10264 |
if (try == 0) {
|
10060 | 10265 |
printf(" Architecture Performance Monitoring Extended (0x23):\n");
|
|
10266 |
print_23_0_ebx(words[WORD_EBX]);
|
10061 | 10267 |
} else if (try == 1) {
|
10062 | |
printf(" general counters bitmap = 0x%0llx\n",
|
|
10268 |
printf(" general counters bitmap = 0x%0llx\n",
|
10063 | 10269 |
(unsigned long long)words[WORD_EAX]);
|
10064 | |
printf(" fixed counters bitmap = 0x%0llx\n",
|
|
10270 |
printf(" fixed counters bitmap = 0x%0llx\n",
|
10065 | 10271 |
(unsigned long long)words[WORD_EBX]);
|
10066 | 10272 |
} else if (try == 2) {
|
10067 | 10273 |
// All reserved
|
|
10384 | 10590 |
printf(" Extended Performance Monitoring and Debugging (0x80000022):\n");
|
10385 | 10591 |
print_80000022_eax(words[WORD_EAX]);
|
10386 | 10592 |
print_80000022_ebx(words[WORD_EBX]);
|
|
10593 |
printf(" active UMCs bitmask = 0x%0x\n",
|
|
10594 |
words[WORD_ECX]);
|
10387 | 10595 |
} else if (reg == 0x80000023) {
|
10388 | 10596 |
printf(" Multi-Key Encrypted Memory Capabilities (0x80000023):\n");
|
10389 | 10597 |
print_80000023_eax(words[WORD_EAX]);
|
|
10599 | 10807 |
status = sched_setaffinity(0, sizeof(cpu_set_t), &cpuset);
|
10600 | 10808 |
#endif
|
10601 | 10809 |
if (status == -1) {
|
10602 | |
if (cpu > 0) {
|
10603 | |
if (errno == EINVAL) return -1;
|
10604 | |
}
|
|
10810 |
if (errno == EINVAL) return -1;
|
10605 | 10811 |
|
10606 | 10812 |
fprintf(stderr,
|
10607 | 10813 |
"%s: unable to setaffinity to cpu %d; errno = %d (%s)\n",
|