Add query for number of XCCs per agent

Change-Id: I4b694b4904ba0326c998356388a62c19a972a7ff


[ROCm/ROCR-Runtime commit: f024d21e3d]
Este commit está contenido en:
David Yat Sin
2023-04-11 21:23:56 +00:00
padre 15114271be
commit 101755c207
Se han modificado 3 ficheros con 12 adiciones y 1 borrados
@@ -385,6 +385,9 @@ hsa_status_t CpuAgent::GetInfo(hsa_agent_info_t attribute, void* value) const {
case HSA_AMD_AGENT_INFO_IOMMU_SUPPORT:
*((hsa_amd_iommu_version_t*)value) = HSA_IOMMU_SUPPORT_NONE;
break;
case HSA_AMD_AGENT_INFO_NUM_XCC:
*((uint32_t*)value) = 0;
break;
default:
return HSA_STATUS_ERROR_INVALID_ARGUMENT;
break;
@@ -1242,6 +1242,9 @@ hsa_status_t GpuAgent::GetInfo(hsa_agent_info_t attribute, void* value) const {
else
*((hsa_amd_iommu_version_t*)value) = HSA_IOMMU_SUPPORT_NONE;
break;
case HSA_AMD_AGENT_INFO_NUM_XCC:
*((uint32_t*)value) = static_cast<uint32_t>(properties_.NumXcc);
break;
default:
return HSA_STATUS_ERROR_INVALID_ARGUMENT;
break;
@@ -387,7 +387,12 @@ typedef enum hsa_amd_agent_info_s {
* Queries for version of IOMMU supported by agent.
* The type of this attribute is hsa_amd_iommu_version_t.
*/
HSA_AMD_AGENT_INFO_IOMMU_SUPPORT = 0xA110
HSA_AMD_AGENT_INFO_IOMMU_SUPPORT = 0xA110,
/**
* Queries for number of XCCs within the agent.
* The type of this attribute is uint32_t.
*/
HSA_AMD_AGENT_INFO_NUM_XCC = 0xA111
} hsa_amd_agent_info_t;
/**