Core sharing validation for CPU isolation
Get series with b4
b4 am [email protected]Versions newest first
- v1 Latest7 patches 0 repliesNew
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/7 | rteval: Add CoreSiblings class for CPU core topology queriesrteval/ | +110 | 0 replies | |
| 2/7 | rteval: Add core sharing validation for CPU isolationrteval-cmd rteval/ rteval/ | +69 | 0 replies | |
| 3/7 | rteval: Include core sharing warnings in XML reportrteval-cmd rteval/ rteval/ | +45 | 0 replies | |
| 4/7 | rteval: Add temporary test for core sharing validation with mocked isolated CPUstest_full_validation.py | +151 | 0 replies | |
| 5/7 | rteval: Display core sharing warnings in text reportrteval/ | +12 | 0 replies | |
| 6/7 | rteval: Add --warn-non-isolated-core-sharing option for measurement vs load warningsrteval-cmd rteval/ | +21 | 0 replies | |
| 7/7 | rteval: Include --warn-non-isolated-core-sharing warnings in XML reportrteval-cmd rteval/ | +6 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.
Cover letter [PATCH 0/7] Core sharing validation for CPU isolation
This patch series adds validation to detect and warn when CPUs sharing physical cores (SMT siblings) are assigned to different workload types, which can defeat CPU isolation and corrupt real-time measurements.
When SMT/hyperthreading is enabled, CPUs sharing a physical core also share L1/L2 caches, execution units, TLB, and other core-level resources. Running different workload types (housekeeping, measurement, load) on sibling threads defeats CPU isolation and can create unreproducible results.
The series implements:
1. CoreSiblings class - Provides a simple interface for querying which CPUs share physical cores by reading thread_siblings_list from sysfs. Works with any SMT configuration (1-way, 2-way, 4-way, 8-way).
2. Core sharing validation - Detects when isolated CPUs share cores between housekeeping, measurement, and load groups. Warnings are logged to console and included in XML reports.
3. XSLT integration - Warnings appear in text reports generated with the -Z option via a CoreSharingWarnings section.
4. Optional stricter validation - --warn-non-isolated-core-sharing flag enables warnings for measurement vs load CPU pairs even when neither is isolated, for users who want maximum isolation assurance.
The validation is purely informational - it warns users but does not prevent execution, allowing informed decisions about CPU configurations.
Testing includes comprehensive scenarios with both isolated and non-isolated CPU configurations, verified with real isolated CPUs.
John Kacur (7):
rteval: Add CoreSiblings class for CPU core topology queries
rteval: Add core sharing validation for CPU isolation
rteval: Include core sharing warnings in XML report
rteval: Add temporary test for core sharing validation with mocked
isolated CPUs
rteval: Display core sharing warnings in text report
rteval: Add --warn-non-isolated-core-sharing option for measurement vs
load warnings
rteval: Include --warn-non-isolated-core-sharing warnings in XML
report
rteval-cmd | 18 +++- rteval/rteval_text.xsl | 13 ++- rteval/sysinfo/__init__.py | 3 + rteval/sysinfo/coresiblings.py | 116 +++++++++++++++++++++++++ rteval/sysinfo/cputopology.py | 35 ++++++++ rteval/systopology.py | 64 ++++++++++++++ test_full_validation.py | 151 +++++++++++++++++++++++++++++++++ 7 files changed, 398 insertions(+), 2 deletions(-) create mode 100644 rteval/sysinfo/coresiblings.py create mode 100644 test_full_validation.py
Signature · 1 line
2.53.0