[llvm] [SPIRV] Let atomic store store pointers (PR #201251)

Nick Sarnie via llvm-commits llvm-commits at lists.llvm.org
Wed Jun 3 08:23:46 PDT 2026


================
@@ -2051,7 +2051,7 @@ bool SPIRVInstructionSelector::selectAtomicStore(MachineInstr &I) const {
 
   SPIRVTypeInst PtrType = GR.getSPIRVTypeForVReg(Ptr);
   SPIRVTypeInst PointeeType = GR.getPointeeType(PtrType);
-  if (!PointeeType.isTypeIntOrFloat())
+  if (!PointeeType.isTypeIntOrFloat() && !PointeeType.isTypePtr())
     return diagnoseUnsupported(I,
                                "Lowering to SPIR-V of atomic store is only "
                                "allowed for integer or floating point types");
----------------
sarnex wrote:

should we update the error message?

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


More information about the llvm-commits mailing list