如何使用过程控制监视器计算 PCIe 插槽的运行时带宽?

如何使用过程控制监视器计算 PCIe 插槽的运行时带宽?

我正在从事深度学习工作并试图找出我们的 GPU 管道中的瓶颈。

我们在配备 4 个 NVIDIA Titan RTX 的 Intel Xeon 主板上运行 Ubuntu。通过 nvidia-smi 测量的 GPU 利用率似乎相当低,即使 GPU 内存使用率约为 97%。

所以我想看看公交车是否是瓶颈。

我已经下载了相控阵相机我正在运行它来监控 PCIe 3.0 x16 流量。

Processor Counter Monitor: PCIe Bandwidth Monitoring Utility 
 This utility measures PCIe bandwidth in real-time

 PCIe event definitions (each event counts as a transfer): 
   PCIe read events (PCI devices reading from memory - application writes to disk/network/PCIe device):
     PCIeRdCur* - PCIe read current transfer (full cache line)
         On Haswell Server PCIeRdCur counts both full/partial cache lines
     RFO*      - Demand Data RFO
     CRd*      - Demand Code Read
     DRd       - Demand Data Read
   PCIe write events (PCI devices writing to memory - application reads from disk/network/PCIe device):
     ItoM      - PCIe write full cache line
     RFO       - PCIe partial Write
   CPU MMIO events (CPU reading/writing to PCIe devices):
     PRd       - MMIO Read [Haswell Server only] (Partial Cache Line)
     WiL       - MMIO Write (Full/Partial)
...
Socket 0: 2 memory controllers detected with total number of 6 channels. 3 QPI ports detected. 2 M2M (mesh to memory) blocks detected.
Socket 1: 2 memory controllers detected with total number of 6 channels. 3 QPI ports detected. 2 M2M (mesh to memory) blocks detected.
Trying to use Linux perf events...
Successfully programmed on-core PMU using Linux perf
Link 3 is disabled
Link 3 is disabled
Socket 0
Max QPI link 0 speed: 23.3 GBytes/second (10.4 GT/second)
Max QPI link 1 speed: 23.3 GBytes/second (10.4 GT/second)
Socket 1
Max QPI link 0 speed: 23.3 GBytes/second (10.4 GT/second)
Max QPI link 1 speed: 23.3 GBytes/second (10.4 GT/second)

Detected Intel(R) Xeon(R) Gold 5122 CPU @ 3.60GHz "Intel(r) microarchitecture codename Skylake-SP" stepping 4 microcode level 0x200004d
Update every 1.0 seconds
delay_ms: 54
Skt | PCIeRdCur |  RFO  |  CRd  |  DRd  |  ItoM  |  PRd  |  WiL
 0      13 K        19 K     0       0      220 K    84     588  
 1       0        3024       0       0        0       0     264  
-----------------------------------------------------------------------
 *      13 K        22 K     0       0      220 K    84     852  

暂时忽略实际值。我的值要大得多。:-)

如何使用过程控制监视器计算 PCIe 插槽的运行时带宽?

为什么只列出两个插座?

答案1

github opcm:

socket 指的是 CPU 插槽,而不是 PCIe 插槽或设备。您的系统有 2 个 CPU 插槽,对吗?--help 输出描述了 -B 开关以输出每个 CPU 插槽的带宽(另请参阅此处的部分操作警告)。pci-iio.x 是一个不同的实用程序,可显示每个 PCIe 设备的带宽。

相关内容