Skip to content

fix: correctly detect Snapdragon X2 SKUs with no name token (issue #2)#5

Merged
spenceriam merged 2 commits into
mainfrom
fix/issue-2-x2-sku-inference
Jul 9, 2026
Merged

fix: correctly detect Snapdragon X2 SKUs with no name token (issue #2)#5
spenceriam merged 2 commits into
mainfrom
fix/issue-2-x2-sku-inference

Conversation

@spenceriam

@spenceriam spenceriam commented Jul 9, 2026

Copy link
Copy Markdown
Owner

Summary

  • Detection was previously assuming the OS always reports a numeric SKU token in ProcessorNameString. It doesn't on this reporter's Surface Laptop 8 (bare "Snapdragon X2 Elite" with no token), which fell into an "Unknown X2 Elite SKU" fallback with Base/Boost/TDP blanked out.
  • Replaces name-token-only matching with a layered pipeline: exact SKU token → family from name/registry Identifier → SKU inferred from real core count + rated clock (~MHz, the same signal CPU-Z/HWiNFO use) → honest family-only fallback with real boost populated → generic. X2E-80-100/X2E-84-100 (CPU-visible-identical specs) get one honest combined label rather than a guess.
  • Fixes a latent bug where every X Elite SKU collapsed to X1E-80-100, and a fabricated "X1P-80-100" table entry (replaced with the real X1P-42/46-100 SKUs).
  • Speed now computed from per-core % Processor Performance × ~MHz (fastest core) instead of a single _Total counter that blends an idle Efficiency cluster into a busy Prime cluster's reported clock.
  • Real OS P/E topology now consistently overrides the static profile table across every match path (not just inferred ones), fixing an internal inconsistency caught during review where a token-matched profile's cluster summary contradicted the real topology reported right next to it.
  • About dialog now shows only the detected processor instead of an unbounded full SKU list; added a "Copy detection report" Tools-menu command so future misdetections can be diagnosed from one pasted block instead of screenshots.

…en (issue #2)

The v0.4.4 fix matched only a numeric SKU token in ProcessorNameString, but
some OEM firmware (the reporter's Surface Laptop 8, X2E-78-100) reports a
bare marketing name with no token at all, so it fell through to "Unknown X2
Elite SKU" with Base/Boost/TDP blanked out every time.

Add a layered detection pipeline (sensors/chips.rs, sensors/identity.rs):
exact SKU token -> family from name or registry Identifier -> SKU inferred
from real core count + rated clock (~MHz, the same signal CPU-Z/HWiNFO use)
-> honest family-only fallback with real boost populated -> generic. Two
SKUs (X2E-80/84-100) publish identical CPU-visible specs and get one honest
combined label instead of a guess. Also fixes a latent bug where every X
Elite SKU collapsed to X1E-80-100, and replaces a fabricated "X1P-80-100"
table entry with the real X1P-42/46-100 SKUs.

Speed now comes from per-core % Processor Performance x ~MHz (the fastest
core), replacing a single _Total counter that blends idle Efficiency cores
into a busy Prime cluster's reported clock. Real OS P/E topology now
consistently overrides the static profile table for every match path, not
just the inferred ones, so the new "Copy detection report" diagnostic
(Tools menu) never contradicts itself.

24 unit tests cover the reported scenario, the ambiguous pair, the
name-independent Identifier path, and X1/X2 token regressions.
ProcessorInfo: Model no longer doubles up on placeholder text ("Snapdragon
X2 Elite Unknown X2 Elite SKU"); CPUID now shows the real registry
Identifier string instead of repeating the marketing model; Model gets a
hover tooltip naming the detection basis when it wasn't an exact SKU token
match.

About dialog: replace the unbounded full SKU-lineup list (which only grows
with every future family) with a single line for the actually-detected
processor, and swap the per-core-temperature disclosure for a general
"this is a monitoring/detection tool, not a benchmark" scope note.

Tools menu: add "Copy detection report", dumping every raw identity signal
plus how the chip was matched to the clipboard — lets a reporter hand over
one paste instead of screenshots for a machine we don't own.
@spenceriam
spenceriam marked this pull request as ready for review July 9, 2026 18:55
@spenceriam
spenceriam merged commit fd20798 into main Jul 9, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant