SWDEV-325711 - add Graph memory APIs skeleton

- hipDeviceGet/SetGraphMemAttr

- hipDeviceGraphMemTrim

- there is no memory pool for graphs currently

Signed-off-by: sdashmiz <shadi.dashmiz@amd.com>
Change-Id: I11db76ea7ea1c7732175fc93264448052357e8dc


[ROCm/hipother commit: 9e3c65ccbd]
This commit is contained in:
sdashmiz
2022-04-04 16:22:16 -04:00
committed by Shadi Dashmiz
parent 92423493b1
commit c6d10a3bf0
@@ -1133,6 +1133,7 @@ typedef enum cudaStreamCaptureStatus hipStreamCaptureStatus;
typedef union cudaKernelNodeAttrValue hipKernelNodeAttrValue;
typedef enum cudaKernelNodeAttrID hipKernelNodeAttrID;
typedef enum cudaGraphMemAttributeType hipGraphMemAttributeType;
#if CUDA_VERSION >= CUDA_11030
typedef enum cudaStreamUpdateCaptureDependenciesFlags hipStreamUpdateCaptureDependenciesFlags;
@@ -3018,6 +3019,18 @@ inline static hipError_t hipGraphExecEventWaitNodeSetEvent(hipGraphExec_t hGraph
hipGraphNode_t hNode, hipEvent_t event) {
return hipCUDAErrorTohipError(cudaGraphExecEventWaitNodeSetEvent(hGraphExec, hNode, event));
}
inline static hipError_t hipDeviceGetGraphMemAttribute(int device, hipGraphMemAttributeType attr, void* value) {
return hipCUDAErrorTohipError(cudaDeviceGetGraphMemAttribute(device, attr, value));
}
inline static hipError_t hipDeviceSetGraphMemAttribute(int device, hipGraphMemAttributeType attr, void* value) {
return hipCUDAErrorTohipError(cudaDeviceSetGraphMemAttribute(device, attr, value));
}
inline static hipError_t hipDeviceGraphMemTrim(int device) {
return hipCUDAErrorTohipError(cudaDeviceGraphMemTrim(device));
}
#endif
inline static hipError_t hipGraphHostNodeSetParams(hipGraphNode_t node,