[PATCH] D94648: [amdgpu] Implement lower function LDS pass

Jon Chesterfield via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jan 28 17:17:53 PST 2021


JonChesterfield added inline comments.


================
Comment at: llvm/test/CodeGen/AMDGPU/lower-function-lds-inactive.ll:36
+  %v2 = atomicrmw add i32 addrspace(3)* @extern, i32 %c0  monotonic
+  %v1 = atomicrmw add i64 addrspace(4)* @addr4, i64 %c1 monotonic
+  ret void
----------------
arsenm wrote:
> Could also use some stores, intrinsic calls, cmpxchg. 
> 
> Also some more exotic users that tend to break, such as storing the value's address to itself
Mixed it up a bit. As far as I can tell, ReplaceAllUsesWith works everywhere other than the compiler.used list, which looks like an oversight. The larger constexpr case has two uses of the same subexpression.

Storing value's address to itself just behaves like any other non-undef initializer, i.e. ignored by the pass. Added to the inactive.ll test set.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D94648/new/

https://reviews.llvm.org/D94648



More information about the llvm-commits mailing list