Unit content
Simultaneous multithreading and logical processors
A physical CPU core contains several execution resources, and one instruction stream does not always keep all of them busy. Simultaneous multithreading (SMT) lets one core maintain architectural state for multiple hardware threads and issue work from more than one thread into the core's execution machinery.
An operating system may expose these hardware threads as separate logical processors. Two logical processors backed by the same core are therefore not equivalent to two independent physical cores.
SMT can improve throughput when one thread is stalled or leaves execution units unused. Another hardware thread may use otherwise idle capacity.
The threads also compete for shared resources such as execution units, caches and memory bandwidth. Two compute-heavy threads placed on sibling logical processors can therefore gain little—or even interfere—compared with placing them on separate cores.
SMT is different from ordinary operating-system time slicing. With SMT, instructions from different hardware threads can be in the execution pipeline during the same period.
Parallel performance measurements should distinguish logical processors, physical cores and sockets rather than assuming that every scheduler-visible CPU contributes the same independent capacity.