[clang] [CIR][CUDA] Add semantic surface reference type (PR #223013)
via cfe-commits
cfe-commits at lists.llvm.org
Sun Sep 13 19:14:23 PDT 2026
================
@@ -401,6 +401,20 @@ def CIR_VPtrType : CIR_Type<"VPtr", "vptr", [
}];
}
+//===----------------------------------------------------------------------===//
+// CUDADeviceSurfaceType
+//===----------------------------------------------------------------------===//
+
+def CIR_CUDADeviceSurfaceType :
+ CIR_Type<"CUDADeviceSurface", "cuda_surface"> {
+ let summary = "CUDA device surface reference type";
+ let description = [{
+ `!cir.cuda_surface` represents a CUDA built-in surface reference in CIR.
+ The type preserves surface semantics at the CIR level and is lowered to
+ the target device representation during lowering to LLVM IR.
----------------
Siya-05 wrote:
Thanks! I’ve updated this to mention the NVPTX i64 representation. The adjacent CUDADeviceTextureType description uses the same “target device representation” wording. Should I also make it NVPTX-specific?
https://github.com/llvm/llvm-project/pull/223013
More information about the cfe-commits
mailing list