Skip to content

Commit c6180d9

Browse files
committed
Comments
1 parent 52f20d7 commit c6180d9

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

llvm/lib/Target/AMDGPU/SIMemoryLegalizer.cpp

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -609,7 +609,7 @@ class SIGfx12CacheControl : public SIGfx11CacheControl {
609609
SIGfx12CacheControl(const GCNSubtarget &ST) : SIGfx11CacheControl(ST) {
610610
// GFX12.0 and GFX12.5 memory models greatly overlap, and in some cases
611611
// the behavior is the same if assuming GFX12.0 in CU mode.
612-
assert(ST.hasGFX1250Insts() ? ST.isCuModeEnabled() : true);
612+
assert(!ST.hasGFX1250Insts() || ST.isCuModeEnabled());
613613
}
614614

615615
bool insertWait(MachineBasicBlock::iterator &MI, SIAtomicScope Scope,
@@ -2630,14 +2630,15 @@ bool SIGfx12CacheControl::finalizeStore(MachineInstr &MI, bool Atomic) const {
26302630
const bool IsRMW = (MI.mayLoad() && MI.mayStore());
26312631
bool Changed = false;
26322632

2633-
// GFX12.5 only: xcnt wait is needed before flat and global atomics stores/rmw
2633+
// GFX12.5 only: xcnt wait is needed before flat and global atomics
2634+
// stores/rmw.
26342635
if (Atomic && ST.requiresWaitXCntBeforeAtomicStores() && TII->isFLAT(MI)) {
26352636
MachineBasicBlock &MBB = *MI.getParent();
26362637
BuildMI(MBB, MI, MI.getDebugLoc(), TII->get(S_WAIT_XCNT_soft)).addImm(0);
26372638
Changed = true;
26382639
}
26392640

2640-
// Remaining fixes do not apply to RMWs
2641+
// Remaining fixes do not apply to RMWs.
26412642
if (IsRMW)
26422643
return Changed;
26432644

llvm/lib/Target/AMDGPU/SOPInstructions.td

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1655,7 +1655,7 @@ let OtherPredicates = [HasImageInsts] in {
16551655

16561656

16571657
let SubtargetPredicate = HasWaitXcnt in {
1658-
def S_WAIT_XCNT_soft : SOPP_Pseudo<"s_soft_wait_xcnt", (ins s16imm:$simm16), "$simm16">;
1658+
def S_WAIT_XCNT_soft : SOPP_Pseudo<"", (ins s16imm:$simm16), "$simm16">;
16591659
}
16601660

16611661
// Represents the point at which a wave must wait for all outstanding direct loads to LDS.

0 commit comments

Comments
 (0)