tsc_khz vs cpu_khz clarification
From: Chunyan Wang
Date: Sat May 09 2020 - 07:11:57 EST
Hello,
I'm trying to understand exactly what the two variables tsc_khz and
cpu_khz represent. Information online seems to suggest:
tsc_khz - Is the frequency of the tsc
cpu_khz - Outputs in /proc/cpuinfo in the processor description, best
I can tell this is the P0 frequency. Some code examples also seem to
translate tsc values to real time with this, implying it is also the
frequency of the tsc.
For AMD the only information I've found states the tsc frequency will
be the P0 frequency. The system under test is an SMP one with 2x "AMD
EPYC 7542 32-Core Processor", which sees the following between 3
successive boots for these values:
boot 1:
tsc_khz 2894561
cpu_khz 2894496
boot 2:
tsc_khz 2894562
cpu_khz 2894578
boot 3:
tsc_khz 2894561
cpu_khz 2894458
I'd like to understand what these values represent given the reported
values above.
Please could you keep me cc'd in responses.
Regards,
Simon