[PATCH] D149938: [AMDGPU][InferAddressSpaces] Only rewrite address-spaces that can be trivially casted to flat for llvm.amdgcn.flat.atomic.{fadd,fmax,fmin}

Juan Manuel Martinez CaamaƱo via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri May 5 01:45:21 PDT 2023


jmmartinez created this revision.
Herald added subscribers: kosarev, foad, kerbowa, hiraditya, arichardson, tpr, dstuttard, yaxunl, jvesely, kzhuravl, arsenm.
Herald added a project: All.
jmmartinez requested review of this revision.
Herald added subscribers: llvm-commits, wdng.
Herald added a project: LLVM.

The intrinsic @llvm.amdgcn.flat.atomic.{fadd,fmax,fmin} can only be
selected for flat address spaces (constant, flat and global).

This patch restricts the cases over which GCNTTIImpl::rewriteIntrinsicWithAddressSpace
rewrites the intrinsic.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D149938

Files:
  llvm/lib/Target/AMDGPU/AMDGPUTargetTransformInfo.cpp
  llvm/test/Transforms/InferAddressSpaces/AMDGPU/flat-fadd-fmin-fmax-intrinsics.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D149938.519771.patch
Type: text/x-patch
Size: 11734 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230505/26b3f5c9/attachment-0001.bin>


More information about the llvm-commits mailing list