kfdtest: SVM mGPU tests skip GPUs prior to gfx9

Otherwise the test failed because KFD returns failure to map or prefetch
the SVM range to those GPUs which don't support SVM.

Change-Id: Ideaec2a686bfabb2fd6ae41b1a690da144121a89
Signed-off-by: Philip Yang <Philip.Yang@amd.com>


[ROCm/ROCR-Runtime commit: c05c66e756]
Este cometimento está contido em:
Philip Yang cometeu 2022-05-02 16:42:03 -04:00
1 ascendente be5d26df01
cometimento ebea654308
1 ficheiro modificado
+22 -4
+22 -4
Ver ficheiro
@@ -997,9 +997,18 @@ TEST_F(KFDSVMRangeTest, MultiGPUMigrationTest) {
return;
}
const std::vector<int> gpuNodes = m_NodeInfo.GetNodesWithGPU();
const std::vector<int> gpuNodesAll = m_NodeInfo.GetNodesWithGPU();
std::vector<int> gpuNodes;
for (int i : gpuNodesAll) {
const HsaNodeProperties *pNodeProperties;
pNodeProperties = m_NodeInfo.GetNodeProperties(gpuNodesAll.at(i));
if (pNodeProperties->Capability.ui32.SVMAPISupported)
gpuNodes.push_back(gpuNodesAll.at(i));
}
if (gpuNodes.size() < 2) {
LOG() << "Skipping test: at least two GPUs needed." << std::endl;
LOG() << "Skipping test: at least two SVM supported GPUs needed." << std::endl;
return;
}
@@ -1072,9 +1081,18 @@ TEST_F(KFDSVMRangeTest, MultiGPUAccessInPlaceTest) {
return;
}
const std::vector<int> gpuNodes = m_NodeInfo.GetNodesWithGPU();
const std::vector<int> gpuNodesAll = m_NodeInfo.GetNodesWithGPU();
std::vector<int> gpuNodes;
for (int i : gpuNodesAll) {
const HsaNodeProperties *pNodeProperties;
pNodeProperties = m_NodeInfo.GetNodeProperties(gpuNodesAll.at(i));
if (pNodeProperties->Capability.ui32.SVMAPISupported)
gpuNodes.push_back(gpuNodesAll.at(i));
}
if (gpuNodes.size() < 2) {
LOG() << "Skipping test: at least two GPUs needed." << std::endl;
LOG() << "Skipping test: at least two SVM supported GPUs needed." << std::endl;
return;
}