gz / rust-cpuid

cpuid library in rust.
https://docs.rs/raw-cpuid/
MIT License
150 stars 45 forks source link

Implement AMD leaf 0x8000_001E (Processor Topology Information) #97

Closed Umio-Yasuno closed 2 years ago

Umio-Yasuno commented 2 years ago

Related: #62

It seems that the result of the comment part of the ryzen_matisse test file and the CPUID value are different.
Do you want to leave it as is?

///   extended APIC ID = 10
///   Core Identifiers (0x8000001e/ebx):
///      core ID          = 0x5 (5)
///      threads per core = 0x2 (2)
///   Node Identifiers (0x8000001e/ecx):
///      node ID             = 0x0 (0)
///      nodes per processor = 0x1 (1)
    0x8000001e_00000000u64 => CpuIdResult { eax: 0x00000000, ebx: 0x00000100, ecx: 0x00000000, edx: 0x00000000 },
gz commented 2 years ago

It seems that the result of the comment part of the ryzen_matisse test file and the CPUID value are different.

yea we should probably adjust the comment here. the reason for this discrepancy is because I ran cpuid twice (once to get the raw output and once to get the description for the comment, and core ID returns different results based on wherever the process happens to run)

gz commented 2 years ago

Great thanks!

Umio-Yasuno commented 2 years ago

Thanks!