Identifying which logical core is hyperthreaded and which one is not
The best way to do it is just to benchmark it.
Write any trivial program that uses 2 threads. Then bind the threads to two cores.
If the performance drops significantly between a pair of cores versus another pair, then you know those two cores are on the same physical core.
I would trust a benchmark like this over whatever anything else tells you.
In Windows, the logical/physical cores are interleaved.
Cores 0,1 are on the same physical core.
Cores 2,3 are on the same...
Cores 4,5 are on the same... etc...
It may be different on Linux.
cpuid: reported micro-architecture seems ambiguous
This is the http://www.etallen.com/cpuid.html version of the cpuid
command, rather than the one that's part of the msr-tools
package.
According to Intel's web site, "Intel(R) Xeon(R) E-2278G" is a Coffee Lake, as your cpuid
shell command figured out from other CPUID info, perhaps including the brand string.
Specifically, according to wikichip, it's a Coffee Lake Refresh iteration of Coffee Lake E (the Xeon-badged versions of "client" cores), so Coffee Lake ER.
Being Coffee Lake means the IA cores are microarchitecturally identical to Skylake (and Kaby Lake), although it has a newer GPU and has memory controllers rated for higher speeds.
For the CPU cores, the improvement is just a refinement of the silicon process (14nm++).
Except maybe for some hardware fix for vulnerabilities like Meltdown, and L1TF or other related things. And maybe refinement of the Spectre mitigations. But not yet fixing the bug that required disabling the LSD (loop buffer) in microcode, or the JCC erratum, so both those performance problems are still self-inflicted by its microcode to ensure correctness even in corner cases.
The PMU hardware is AFAIK identical in SKL, KBL, and CFL, except perhaps(?) some errata being fixed. The event IDs are all the same, I assume.
Understanding command-line cpuid
output:
version information (1/eax):
... family/model/stepping/...
(simple synth) = Intel Core (unknown type) (Kaby Lake / Coffee Lake) {Skylake}, 14nm
I'm guessing that this is saying that the family/model/stepping and extended-model/family fields don't distinguish between KBL and CFL (thus unknown type), but do imply one or the other. And {Skylake}
is reminding you that KBL and CFL are both iterations of Skylake.
The "(unknown type)" is probably saying it doesn't know whether it's an i3/5/7/9 or Pentium or Celeron.
On my i7-6700k Skylake desktop, I get this. From cpuid version 20170122
from an old Arch Linux AUR install, which is still over a year after the CPU itself was released, which may be an older version than you have.
version information (1/eax):
processor type = primary processor (0)
family = Intel Pentium Pro/II/III/Celeron/Core/Core 2/Atom, AMD Athlon/Duron, Cyrix M2, VIA C3 (6)
model = 0xe (14)
stepping id = 0x3 (3)
extended family = 0x0 (0)
extended model = 0x5 (5)
(simple synth) = Intel Core i3-6000 / i5-6000 / i7-6000 / Pentium G4000 / Celeron G3900 / Xeon E3-1200 (Skylake), 14nm
So yeah, (simple synth) is probably what it was able to divine from just the things in that leaf, not the brand string.
From the latest version of the tool, version 20220224
,
version information (1/eax):
processor type = primary processor (0)
family = 0x6 (6)
model = 0xe (14)
...
(family synth) = 0x6 (6)
(model synth) = 0x5e (94)
(simple synth) = Intel Core (unknown type) (Skylake-H R0) {Skylake}, 14nm
...
(uarch synth) = Intel Skylake {Skylake}, 14nm
(synth) = Intel Core i*-6000 (Skylake-H R0) {Skylake}, 14nm
So the (unknown type)
seems perfectly normal, just a consequence of Intel not varying the family, model, stepping numbers across i3/5/7.
The version of cpuid
in your Ubuntu 20.04 LTS does seem to know about Coffee Lake, though. Perhaps not new enough to know about Coffee Lake Refresh, since yours said "R0" for yours, same as "R0" for my Skylake (which is not a "refresh"; there weren't new iterations of CPUs released as Skylake. They moved straight on to Kaby Lake after SKL.)
Anyway, your version of cpuid
does eventually get to a correct and fully accurate description of your CPU, synthesized from various pieces of information.
(synth) = Intel Xeon E-2200 (Coffee Lake R0) {Skylake}, 14nm
I'm not sure exactly what cpuid
means by R0. Perhaps "revision 0", which would make sense if it didn't know about "Coffee Lake Refresh". I wonder if a newer cpuid
would report R1 or spell out "Refresh"?
It is indeed an E-22xx series Xeon of the Coffee Lake family. The CPU cores are basically identical to Skylake, and it's built in a 14nm(++) process. IDK if Intel tweaked anything at all inside the cores between CFL and CFL-refresh, so for programming it you have all the info you need.
Other instances of "R" show up in CPUID output that mean "registered trademark" like in "Intel(R) Xeon(R)" in the brand string Intel(R) Xeon(R) E-2278G CPU @ 3.40GHz
that Linux pulls directly out of the CPU via the EAX=0017h leaf of the CPUID machine instruction with different ECX inputs. But I think the R0 is probably being used to mean "first iteration" (0th refresh?), since it's not just copying strings like "Xeon(R)".
Disable Hyperthreading online
I am not sure which CPU or node shall I go to and perform the following operation
based on the numbers of CPU cores, siblings in the system.
Parallel benchmarking the system would assess performance and maximum throughput of a multi core CPU's, which can tell us enabling/disabling of hyper threading for the system.
Related Topics
How to Run 16 Bit Code on 32 Bit Linux
"Sort Filename | Uniq" Does Not Work on Large Files
How to Concatenate Svg Files Lengthwise from Linux Command Line
How to Run an Image Windows Docker on Ubuntu
Quickest Way to Select/Copy Lines Containing String from Huge Txt.Gz File
How to Solve Ssh: /Usr/Lib64/Libcrypto.So.10: No Version Information Available
Removing Parts of a String That Contain Digit with Sed/Perl
Accessing Apache2 Residing Inside Docker Container from Host Machine Web Browser
Perl System Calls When Running as Another User Using Sudo
Converting Linux Svn Repos to Windows Svn Repos
Linux Bash Commands to Remove Duplicates from a CSV File
Bash - Process Backspace Control Character When Redirecting Output to File
Init Script '/Dev/Tty: No Such Device or Address' Error on Redirect
Visual Studio 2017 Could Not Create Directories, Mkdir Exit Code: 1
How to Show Printk() Message in Console
Numa-Aware Named Shared Memory for Linux
What Algorithm How to Use to Generate a 48-Bit Hash for Unique MAC Addresses