From 64a70c909740ce61b40cedc2d89d5b57d58f968c Mon Sep 17 00:00:00 2001 From: Ankith Averineni Date: Tue, 14 Jul 2026 01:06:36 -0700 Subject: [PATCH] [AMD] jit_kernel: complete utils.cuh HIP-compat (cudaDevAttr / cudaDeviceGetAttribute) (#31143) --- python/sglang/jit_kernel/include/sgl_kernel/utils.cuh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/python/sglang/jit_kernel/include/sgl_kernel/utils.cuh b/python/sglang/jit_kernel/include/sgl_kernel/utils.cuh index c5681b933..82974a99a 100644 --- a/python/sglang/jit_kernel/include/sgl_kernel/utils.cuh +++ b/python/sglang/jit_kernel/include/sgl_kernel/utils.cuh @@ -48,6 +48,9 @@ inline constexpr auto cudaSuccess = hipSuccess; #define cudaMemcpyAsync hipMemcpyAsync #define cudaMemcpyHostToDevice hipMemcpyHostToDevice #define cudaMemcpyDeviceToHost hipMemcpyDeviceToHost +#define cudaDeviceGetAttribute hipDeviceGetAttribute +#define cudaDevAttrComputeCapabilityMajor hipDeviceAttributeComputeCapabilityMajor +#define cudaDevAttrComputeCapabilityMinor hipDeviceAttributeComputeCapabilityMinor #endif #ifndef USE_ROCM