Fix detection of support for cooperative groups (#1932)
Query ROCr to see if we have the proper lower-level support for cooperative groups -- GWS support through the firmware, driver, thunk, and ROCr. ROCr does these checks for us, and presents a query that allows us to see if GWS entries are available for use. If so, then we have all the lower-level technologies needed, and we should enable cooperative groups support for HIP.
This commit is contained in:
committed by
GitHub
parent
4a9793e2e2
commit
35a68596f9
@@ -895,9 +895,11 @@ hipError_t ihipDevice_t::initProperties(hipDeviceProp_t* prop) {
|
||||
prop->integrated = 1;
|
||||
}
|
||||
|
||||
// Enable the cooperative group for gfx9+
|
||||
prop->cooperativeLaunch = (prop->gcnArch < 900) ? 0 : 1;
|
||||
prop->cooperativeMultiDeviceLaunch = (prop->gcnArch < 900) ? 0 : 1;
|
||||
// Enable the cooperative group for GPUs that support all the required features
|
||||
err = hsa_agent_get_info(_hsaAgent, (hsa_agent_info_t)HSA_AMD_AGENT_INFO_COOPERATIVE_QUEUES,
|
||||
&prop->cooperativeLaunch);
|
||||
DeviceErrorCheck(err);
|
||||
prop->cooperativeMultiDeviceLaunch = prop->cooperativeLaunch;
|
||||
|
||||
prop->cooperativeMultiDeviceUnmatchedFunc = prop->cooperativeMultiDeviceLaunch;
|
||||
prop->cooperativeMultiDeviceUnmatchedGridDim = prop->cooperativeMultiDeviceLaunch;
|
||||
|
||||
Reference in New Issue
Block a user