[clang] [llvm] [SPIRV] Handle AMDGPU buffers in AMDGCN flavoured SPIR-V (PR #199376)

Vyacheslav Levytskyy via cfe-commits cfe-commits at lists.llvm.org
Sat May 23 15:23:40 PDT 2026


================
@@ -54,7 +54,9 @@ SPIRVSubtarget::SPIRVSubtarget(const Triple &TT, const std::string &CPU,
                                const std::string &FS,
                                const SPIRVTargetMachine &TM)
     : SPIRVGenSubtargetInfo(TT, CPU, /*TuneCPU=*/CPU, FS),
-      PointerSize(TM.getPointerSizeInBits(/* AS= */ 0)),
+      PointerSize(TM.getPointerSizeInBits(
+          /* AS= */ storageClassToAddressSpace(SPIRV::StorageClass::Generic,
----------------
VyacheslavLevytskyy wrote:

This switch from AS0 to AS4 is not mentioned/discussed in the PR description.

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


More information about the cfe-commits mailing list