[llvm-branch-commits] [llvm] [NFC][AMDGPU] Refactor handling of `amdgpu-synchronize-as` MD on fences (PR #148630)
Shilei Tian via llvm-branch-commits
llvm-branch-commits at lists.llvm.org
Wed Jul 23 07:48:46 PDT 2025
================
@@ -903,12 +906,19 @@ SIMemOpAccess::getAtomicFenceInfo(const MachineBasicBlock::iterator &MI) const {
std::tie(Scope, OrderingAddrSpace, IsCrossAddressSpaceOrdering) =
*ScopeOrNone;
- if ((OrderingAddrSpace == SIAtomicAddrSpace::NONE) ||
- ((OrderingAddrSpace & SIAtomicAddrSpace::ATOMIC) != OrderingAddrSpace)) {
+ if (OrderingAddrSpace != SIAtomicAddrSpace::ATOMIC) {
+ // We currently expect refineOrderingAS to be the only place that
+ // can refine the AS ordered by the fence.
+ // If that changes, we need to review the semantics of that function
+ // in case it needs to preserve certain address spaces.
reportUnsupported(MI, "Unsupported atomic address space");
return std::nullopt;
}
+ auto SynchronizeAS = getSynchronizeAddrSpaceMD(*MI);
----------------
shiltian wrote:
nit: no auto
https://github.com/llvm/llvm-project/pull/148630
More information about the llvm-branch-commits
mailing list