[SWDEV-482412] Optimized PCIe Bandwidth gpu_metrics calls

Signed-off-by: Maisam Arif <Maisam.Arif@amd.com>
Change-Id: Ib37d232b94a080e9b490dd065628d2567aaf4642


[ROCm/amdsmi commit: 787d4462fa]
이 커밋은 다음에 포함됨:
Maisam Arif가 2024-09-11 23:26:30 -05:00를 커밋했습니다
1 부모 ae9d7a098c
커밋 cabbdf44cb
7 파일이 변경됨
+123 -103

검색과 일치하는 파일 없음

+1 -1
파일 보기
@@ -810,7 +810,7 @@ except AmdSmiException as e:
### amdsmi_get_pcie_info
Description: Returns the pcie metric and static information for the given GPU.
Description: Returns the pcie metric and static information for the given GPU. For accurate PCIe Bandwidth measurements it is recommended to use this function once per 1000ms
It is not supported on virtual machine guest
Input parameters:
+4 -4
파일 보기
@@ -4073,12 +4073,12 @@ def amdsmi_get_gpu_metrics_header_info(
header_info = amdsmi_wrapper.amd_metrics_table_header_t()
_check_res(
amdsmi_wrapper.amdsmi_get_gpu_metrics_header_info(
ctypes.byref(header_info)
processor_handle, ctypes.byref(header_info)
)
)
return {
"structure_size": header_info.structure_size.value,
"format_revision": header_info.format_revision.value,
"content_revision": header_info.content_revision.value
"structure_size": header_info.structure_size,
"format_revision": header_info.format_revision,
"content_revision": header_info.content_revision
}