[llvm] [AMDGPU] Fix sub-dword atomic flat saddr store with no D16. NFCI (PR #160253)
via llvm-commits
llvm-commits at lists.llvm.org
Tue Sep 23 01:01:52 PDT 2025
llvmbot wrote:
<!--LLVM PR SUMMARY COMMENT-->
@llvm/pr-subscribers-backend-amdgpu
Author: Stanislav Mekhanoshin (rampitec)
<details>
<summary>Changes</summary>
The pattern does not factor saddr. There is no way to write a test
for it because gfx1200 does not have sram-ecc but also no saddr,
and gfx1250 does not fall into this preserving category while has
sram-ecc. Nevertheless, the day we could fix it that would become a
problem. For now it is OK that change does not fail.
That was untested before and it is untested now, but at least t16
block uses t16 patterns.
---
Full diff: https://github.com/llvm/llvm-project/pull/160253.diff
1 Files Affected:
- (modified) llvm/lib/Target/AMDGPU/FLATInstructions.td (+2-2)
``````````diff
diff --git a/llvm/lib/Target/AMDGPU/FLATInstructions.td b/llvm/lib/Target/AMDGPU/FLATInstructions.td
index 7e5ae25ff30e6..9f33bac4c56ea 100644
--- a/llvm/lib/Target/AMDGPU/FLATInstructions.td
+++ b/llvm/lib/Target/AMDGPU/FLATInstructions.td
@@ -2009,8 +2009,8 @@ let OtherPredicates = [D16PreservesUnusedBits, HasFlatAddressSpace], True16Predi
defm : FlatLoadPats_D16_t16<FLAT_LOAD_SBYTE_D16_t16, atomic_load_sext_8_flat, i16>;
defm : FlatStorePats_t16 <FLAT_STORE_BYTE, truncstorei8_flat, i16>;
defm : FlatStorePats_t16 <FLAT_STORE_SHORT, store_flat, i16>;
- def : FlatStorePat <FLAT_STORE_BYTE_t16, atomic_store_8_flat, i16>;
- def : FlatStorePat <FLAT_STORE_SHORT_t16, atomic_store_16_flat, i16>;
+ defm : FlatStorePats_t16 <FLAT_STORE_BYTE, atomic_store_8_flat, i16>;
+ defm : FlatStorePats_t16 <FLAT_STORE_SHORT, atomic_store_16_flat, i16>;
} // End let OtherPredicates = [D16PreservesUnusedBits, HasFlatAddressSpace], True16Predicate = UseRealTrue16Insts
defm : FlatLoadPats <FLAT_LOAD_DWORD, atomic_load_nonext_32_flat, i32>;
``````````
</details>
https://github.com/llvm/llvm-project/pull/160253
More information about the llvm-commits
mailing list