[llvm] [SPIRV] Do not use OpTypeRuntimeArray in Kernel env. (PR #149522)

Steven Perron via llvm-commits llvm-commits at lists.llvm.org
Wed Jul 30 07:07:05 PDT 2025


================
@@ -2367,6 +2371,29 @@ void SPIRVEmitIntrinsics::applyDemangledPtrArgTypes(IRBuilder<> &B) {
   }
 }
 
+GetElementPtrInst *
+SPIRVEmitIntrinsics::simplifyZeroLengthArrayGepInst(GetElementPtrInst *GEP) {
----------------
s-perron wrote:

That is correct. There are only two ways to get an unbounded array in HLSL. The array of resources will will be hidden behind intrinsics. The other is the contents of a structured buffer. That array will be indexed via the `resource_getpointer` intrinsic, and not a GEP.

https://github.com/llvm/llvm-project/pull/149522


More information about the llvm-commits mailing list