SWDEV-539145 - Return error when ext_fine_grain_pool unavailable (#877)
Return error when ext_fine_grain_pool is unavailable for hipHostMallocUncached, hipHostAllocUncached and hipExtHostRegisterUncached. Disable related tests on Navi4x where ext_fine_grain_pool is unavailable
This commit is contained in:
@@ -268,6 +268,28 @@ static inline bool IsGfx11() {
|
||||
#endif
|
||||
}
|
||||
|
||||
static inline bool IsNavi4X() {
|
||||
#if HT_NVIDIA
|
||||
return false;
|
||||
#elif HT_AMD
|
||||
int device = -1;
|
||||
hipDeviceProp_t props{};
|
||||
HIP_CHECK(hipGetDevice(&device));
|
||||
HIP_CHECK(hipGetDeviceProperties(&props, device));
|
||||
std::string arch = std::string(props.gcnArchName);
|
||||
if (arch.find("gfx1200") != std::string::npos ||
|
||||
arch.find("gfx1201") != std::string::npos) {
|
||||
// gfx1200 = Navi44, gfx1201 = Navi48
|
||||
return true;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
#else
|
||||
std::cout << "Have to be either Nvidia or AMD platform, asserting" << std::endl;
|
||||
assert(false);
|
||||
#endif
|
||||
}
|
||||
|
||||
// Utility Functions
|
||||
namespace HipTest {
|
||||
static inline int getDeviceCount() {
|
||||
|
||||
Reference in New Issue
Block a user