Enabling hipGetDeviceFlags required in [SWDEV-229170]

Change-Id: I998d37e5847f9651345554bada86df6fce86d1eb
This commit is contained in:
Sarbojit Sarkar
2020-05-07 03:57:58 -04:00
parent af4692f838
commit 3612851809
6 changed files with 28 additions and 4 deletions
+8
View File
@@ -506,6 +506,14 @@ hipError_t hipFuncSetCacheConfig(const void* func, hipFuncCache_t config);
*/
hipError_t hipDeviceGetSharedMemConfig(hipSharedMemConfig* pConfig);
/**
* @brief Gets the flags set for current device
*
* @param [out] flags
*
* @returns #hipSuccess, #hipErrorInvalidDevice, #hipErrorInvalidValue
*/
hipError_t hipGetDeviceFlags(unsigned *flags);
/**
* @brief The bank width of shared memory on current device is set
@@ -1511,6 +1511,10 @@ inline static hipError_t hipProfilerStart() { return hipCUDAErrorTohipError(cuda
inline static hipError_t hipProfilerStop() { return hipCUDAErrorTohipError(cudaProfilerStop()); }
inline static hipError_t hipGetDeviceFlags(unsigned int* flags) {
return hipCUDAErrorTohipError(cudaGetDeviceFlags(flags));
}
inline static hipError_t hipSetDeviceFlags(unsigned int flags) {
return hipCUDAErrorTohipError(cudaSetDeviceFlags(flags));
}