Closed Bug 1796282 Opened 3 years ago Closed 3 years ago

Crash Reporter does not report some AMD Zen processor's microcode version properly

Categories

(Toolkit :: Crash Reporting, defect)

x86_64
All
defect

Tracking

()

RESOLVED FIXED
109 Branch
Tracking Status
firefox109 --- fixed

People

(Reporter: cmartin, Assigned: gsvelto)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

On my Ryzen 5 1400 machine, the windows registry key used by this code, HLMK\\HARDWARE\\DESCRIPTION\\System\\CentralProcessor\\0\\Update Revision, contains this REG_BINARY sequence: 38 11 00 08 00 00 00 00

This should correspond to microcode version 0x08001138, but instead it sees that the upper 32-bits is zero and doesn't annotate the report at all.

Summary: Crash Reporter does not report AMD Ryzen 5 1400 microcode properly → Crash Reporter does not report some AMD Zen processor's microcode version properly

@ryanvm experiences the same issue with his Zen2-based Threadripper. Its Update Revision is REG_BINARY: 4D 10 30 08 00 00 00 00

See Also: → 1796126

FYI information I've filed an issue in the stack walker tracker to make detecting these crashes an easier job. This is something that would have been impossible with the old Breakpad-based stackwalker but which is now pretty easy to implement.

The severity field is not set for this bug.
:gsvelto, could you have a look please?

For more information, please visit auto_nag documentation.

Flags: needinfo?(gsvelto)
Severity: -- → S3
Flags: needinfo?(gsvelto)

Turns out things aren't as straightforward as they look here, there's some CPU-dependent magic involved. I tested my Intel machine and it has this in the HLMK\HARDWARE\DESCRIPTION\System\CentralProcessor\0\Update Revision key: 00 00 00 00 f0 00 00 00. Linux and Windows-specific tools like CPU-Z report this as microcode version f0. My AMD machine has this in the registry key: 16 10 20 0a 00 00 00 00 but the microcode version is reported to be 0xa201016. Turns out Intel and AMD both report the microcode version in an MSR but they couldn't agree over it, so Intel reports the value in the upper 32 bits of the register, and AMD in the lower 32 bits. Windows helpfully crams the entire contents of the register in the HLMK\HARDWARE\DESCRIPTION\System\CentralProcessor\0\Update Revision key. This will require a bit more complexity to handle and I'll be explicitly masking the bits that aren't supposed to be used because both Intel and AMD manuals claim that they're reserved and not zero. So unless Windows is masking them already there's a good chance we'll also see garbage there in the future.

Assignee: nobody → gsvelto
Status: NEW → ASSIGNED
Pushed by gsvelto@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/14146ec541db Record the CPU microcode version of AMD CPUs correctly in crash reports r=cmartin
Status: ASSIGNED → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → 109 Branch
Blocks: cpu-bugs
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: