Merge pull request #951 from tycho/nvcc-hipDeviceSetCacheConfig
nvcc_detail/hip_runtime_api.h: add missing hipDeviceSetCacheConfig API
[ROCm/clr commit: 44309ee879]
This commit is contained in:
@@ -79,6 +79,12 @@ typedef enum hipChannelFormatKind {
|
|||||||
#define hipBoundaryModeTrap cudaBoundaryModeTrap
|
#define hipBoundaryModeTrap cudaBoundaryModeTrap
|
||||||
#define hipBoundaryModeClamp cudaBoundaryModeClamp
|
#define hipBoundaryModeClamp cudaBoundaryModeClamp
|
||||||
|
|
||||||
|
// hipFuncCache
|
||||||
|
#define hipFuncCachePreferNone cudaFuncCachePreferNone
|
||||||
|
#define hipFuncCachePreferShared cudaFuncCachePreferShared
|
||||||
|
#define hipFuncCachePreferL1 cudaFuncCachePreferL1
|
||||||
|
#define hipFuncCachePreferEqual cudaFuncCachePreferEqual
|
||||||
|
|
||||||
// hipResourceType
|
// hipResourceType
|
||||||
#define hipResourceType cudaResourceType
|
#define hipResourceType cudaResourceType
|
||||||
#define hipResourceTypeArray cudaResourceTypeArray
|
#define hipResourceTypeArray cudaResourceTypeArray
|
||||||
@@ -614,6 +620,10 @@ inline static hipError_t hipDeviceGetCacheConfig(hipFuncCache_t* pCacheConfig) {
|
|||||||
return hipCUDAErrorTohipError(cudaDeviceGetCacheConfig(pCacheConfig));
|
return hipCUDAErrorTohipError(cudaDeviceGetCacheConfig(pCacheConfig));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
inline static hipError_t hipDeviceSetCacheConfig(hipFuncCache_t cacheConfig) {
|
||||||
|
return hipCUDAErrorTohipError(cudaDeviceSetCacheConfig(cacheConfig));
|
||||||
|
}
|
||||||
|
|
||||||
inline static const char* hipGetErrorString(hipError_t error) {
|
inline static const char* hipGetErrorString(hipError_t error) {
|
||||||
return cudaGetErrorString(hipErrorToCudaError(error));
|
return cudaGetErrorString(hipErrorToCudaError(error));
|
||||||
}
|
}
|
||||||
|
|||||||
مرجع در شماره جدید
Block a user