* Reapply "Upgrade ROCm-SMI to AMD SMI (#86)"
This reverts commit b3eee295dd.
---------
Signed-off-by: Carrie Fallows <Carrie.Fallows@amd.com>
Co-authored-by: David Galiffi <David.Galiffi@amd.com>
这个提交包含在:
+28
-5
@@ -22,18 +22,41 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#if ROCPROFSYS_USE_ROCM > 0
|
||||
# include <amd_smi/amdsmi.h>
|
||||
#endif
|
||||
|
||||
namespace rocprofsys
|
||||
{
|
||||
namespace gpu
|
||||
{
|
||||
#if ROCPROFSYS_USE_ROCM > 0
|
||||
void
|
||||
get_processor_handles();
|
||||
|
||||
uint32_t
|
||||
get_processor_count();
|
||||
|
||||
amdsmi_processor_handle
|
||||
get_handle_from_id(uint32_t dev_id);
|
||||
|
||||
struct processors
|
||||
{
|
||||
static uint32_t total_processor_count;
|
||||
static std::vector<amdsmi_processor_handle> processors_list;
|
||||
|
||||
private:
|
||||
friend void rocprofsys::gpu::get_processor_handles();
|
||||
friend uint32_t rocprofsys::gpu::get_processor_count();
|
||||
friend amdsmi_processor_handle rocprofsys::gpu::get_handle_from_id(uint32_t dev_id);
|
||||
};
|
||||
#endif
|
||||
|
||||
int
|
||||
device_count();
|
||||
|
||||
int
|
||||
rocm_device_count();
|
||||
|
||||
int
|
||||
rsmi_device_count();
|
||||
bool
|
||||
initialize_amdsmi();
|
||||
|
||||
void
|
||||
add_device_metadata();
|
||||
|
||||
在新工单中引用
屏蔽一个用户