andre-richter / pcie-lat

Generic x86_64 PCIe latency measurement module for the Linux kernel
GNU General Public License v2.0
56 stars 15 forks source link

TSC Frequency not probed correctly #2

Closed danfruehauf closed 4 years ago

danfruehauf commented 5 years ago

On a server I'm running this utility on, I encounter unreasonable clock frequencies.

For example:

TSC freq:     1034704.0 Hz
TSC overhead: 27 cycles

The clock frequency is actually 5GHz. This yields unlikely PCIe latency results, like:

       | Results (1000 samples)
------------------------------------------------------
Mean   |  11218.96 cycles | 10842679.65 ns
Stdd   |    390.80 cycles | 377693.83 ns
andre-richter commented 5 years ago

Disclaimer: I haven't used this tool in a long time.

The TSC frequency in this case is probed by the Linux kernel directly. My driver just uses the symbol tsc_khz that Linux is exporting.

Unless something goes wrong when the ruby script queries it, I think you need to check the kernel 🤔

andre-richter commented 4 years ago

Closing. #3 most likely fixed this.