[llvm] Fix attributes of llvm.amdgcn.make.buffer.rsrc (PR #68609)

Krzysztof Drewniak via llvm-commits llvm-commits at lists.llvm.org
Mon Oct 9 09:33:58 PDT 2023


https://github.com/krzysz00 created https://github.com/llvm/llvm-project/pull/68609

Per discussion on https://github.com/llvm/llvm-project/pull/68453 , the make_buffer_rsrc intrinsic was incorrectly marked noclobber. This commit fixes the issue.

>From 3a3844a40c18e6fc717cb29e1448c3b3bafd50ec Mon Sep 17 00:00:00 2001
From: Krzysztof Drewniak <Krzysztof.Drewniak at amd.com>
Date: Mon, 9 Oct 2023 16:31:49 +0000
Subject: [PATCH] Fix attributes of llvm.amdgcn.make.buffer.rsrc

Per discussion on https://github.com/llvm/llvm-project/pull/68453 ,
the make_buffer_rsrc intrinsic was incorrectly marked noclobber. This
commit fixes the issue.
---
 llvm/include/llvm/IR/IntrinsicsAMDGPU.td | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/llvm/include/llvm/IR/IntrinsicsAMDGPU.td b/llvm/include/llvm/IR/IntrinsicsAMDGPU.td
index 4f42462f655e260..0df66e1ffc519f2 100644
--- a/llvm/include/llvm/IR/IntrinsicsAMDGPU.td
+++ b/llvm/include/llvm/IR/IntrinsicsAMDGPU.td
@@ -999,7 +999,7 @@ def int_amdgcn_make_buffer_rsrc : DefaultAttrsIntrinsic <
    llvm_i32_ty,    // NumRecords / extent
    llvm_i32_ty],   // flags
   // Attributes lifted from ptrmask + some extra argument attributes.
-  [IntrNoMem, NoCapture<ArgIndex<0>>, ReadNone<ArgIndex<0>>,
+  [IntrNoMem, ReadNone<ArgIndex<0>>,
    IntrSpeculatable, IntrWillReturn]>;
 
 defset list<AMDGPURsrcIntrinsic> AMDGPUBufferIntrinsics = {
@@ -1928,7 +1928,7 @@ def int_amdgcn_inverse_ballot :
             [IntrNoMem, IntrWillReturn, IntrNoCallback, IntrNoFree]>;
 
 class AMDGPUWaveReduce<LLVMType data_ty = llvm_anyint_ty> : Intrinsic<
-    [data_ty], 
+    [data_ty],
     [
       LLVMMatchType<0>,   // llvm value to reduce (SGPR/VGPR)
       llvm_i32_ty         // Reduction Strategy Switch for lowering ( 0: Default,



More information about the llvm-commits mailing list