We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 902fe02 commit 6943906Copy full SHA for 6943906
llvm/lib/Target/RISCV/RISCVGISel.td
@@ -118,7 +118,7 @@ let Predicates = [HasAtomicLdSt] in {
118
}
119
120
let Predicates = [HasAtomicLdSt, IsRV64] in {
121
- def : LdPat<atomic_load_nonext_32, LW, i32>;
+ // Load pattern is in RISCVInstrInfoA.td and shared with RV32.
122
def : StPat<atomic_store_32, SW, GPR, i32>;
123
124
llvm/lib/Target/RISCV/RISCVInstrInfoA.td
@@ -174,15 +174,14 @@ let Predicates = [HasAtomicLdSt] in {
174
def : StPat<relaxed_store<atomic_store_8>, SB, GPR, XLenVT>;
175
def : StPat<relaxed_store<atomic_store_16>, SH, GPR, XLenVT>;
176
def : StPat<relaxed_store<atomic_store_32>, SW, GPR, XLenVT>;
177
-}
178
179
-let Predicates = [HasAtomicLdSt, IsRV32] in {
180
- def : LdPat<relaxed_load<atomic_load_nonext_32>, LW>;
+ // Used by GISel for RV32 and RV64.
+ def : LdPat<relaxed_load<atomic_load_nonext_32>, LW, i32>;
181
182
183
184
- def : LdPat<relaxed_load<atomic_load_asext_32>, LW>;
185
- def : LdPat<relaxed_load<atomic_load_zext_32>, LWU>;
+ def : LdPat<relaxed_load<atomic_load_asext_32>, LW, i64>;
+ def : LdPat<relaxed_load<atomic_load_zext_32>, LWU, i64>;
186
def : LdPat<relaxed_load<atomic_load_nonext_64>, LD, i64>;
187
def : StPat<relaxed_store<atomic_store_64>, SD, GPR, i64>;
188
0 commit comments