From ff34ff30935253786d703f0be42d2f8a0fd803c9 Mon Sep 17 00:00:00 2001 From: Rahul Manocha Date: Tue, 23 Jan 2024 18:15:51 +0000 Subject: [PATCH] SWDEV-421025 Graph Kernel Node Attr ID/Value for Nvidia Change-Id: Ia4676acbadf30fab4041ac7939c8dc6e3996b4e7 [ROCm/hipother commit: 8195ac393a4b91a86e616137f4e006ddf0832708] --- .../nvidia_detail/nvidia_hip_runtime_api.h | 23 +++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/projects/hipother/hipnv/include/hip/nvidia_detail/nvidia_hip_runtime_api.h b/projects/hipother/hipnv/include/hip/nvidia_detail/nvidia_hip_runtime_api.h index eb62087274..391ee8d90c 100644 --- a/projects/hipother/hipnv/include/hip/nvidia_detail/nvidia_hip_runtime_api.h +++ b/projects/hipother/hipnv/include/hip/nvidia_detail/nvidia_hip_runtime_api.h @@ -1574,6 +1574,20 @@ typedef union cudaKernelNodeAttrValue hipKernelNodeAttrValue; typedef enum cudaKernelNodeAttrID hipKernelNodeAttrID; #define hipKernelNodeAttributeAccessPolicyWindow cudaKernelNodeAttributeAccessPolicyWindow #define hipKernelNodeAttributeCooperative cudaKernelNodeAttributeCooperative +#define hipKernelNodeAttributePriority cudaKernelNodeAttributePriority + +#if CUDA_VERSION >= CUDA_12000 +typedef enum cudaGraphInstantiateResult hipGraphInstantiateResult; +#define hipGraphInstantiateSuccess cudaGraphInstantiateSuccess +#define hipGraphInstantiateError cudaGraphInstantiateError +#define hipGraphInstantiateInvalidStructure cudaGraphInstantiateInvalidStructure +#define hipGraphInstantiateNodeOperationNotSupported cudaGraphInstantiateNodeOperationNotSupported +#define hipGraphInstantiateMultipleDevicesNotSupported \ + cudaGraphInstantiateMultipleDevicesNotSupported + +#define hipGraphInstantiateParams cudaGraphInstantiateParams +#endif + typedef enum cudaAccessProperty hipAccessProperty; #define hipAccessPropertyNormal cudaAccessPropertyNormal #define hipAccessPropertyStreaming cudaAccessPropertyStreaming @@ -3595,6 +3609,15 @@ inline static hipError_t hipGraphInstantiate(hipGraphExec_t* pGraphExec, hipGrap cudaGraphInstantiate(pGraphExec, graph, pErrorNode, pLogBuffer, bufferSize)); } +#if CUDA_VERSION >= CUDA_12000 +inline static hipError_t hipGraphInstantiateWithParams(hipGraphExec_t* pGraphExec, hipGraph_t graph, + hipGraphInstantiateParams *instantiateParams) + { + return hipCUDAErrorTohipError(cudaGraphInstantiateWithParams(pGraphExec, graph, + instantiateParams)); +} +#endif + #if CUDA_VERSION >= CUDA_11040 inline static hipError_t hipGraphInstantiateWithFlags(hipGraphExec_t* pGraphExec, hipGraph_t graph, unsigned long long flags) {