Skip to content

Commit 6b3289f

Browse files
authored
ARM: Remove unnecessary use_empty check (#137338)
The previous statement removed all uses.
1 parent 50a767a commit 6b3289f

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

llvm/lib/Target/ARM/MVEGatherScatterLowering.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1099,8 +1099,7 @@ bool MVEGatherScatterLowering::optimiseOffsets(Value *Offsets, BasicBlock *BB,
10991099

11001100
// The instruction has now been "absorbed" into the phi value
11011101
Offs->replaceAllUsesWith(NewPhi);
1102-
if (Offs->use_empty())
1103-
Offs->eraseFromParent();
1102+
Offs->eraseFromParent();
11041103
// Clean up the old increment in case it's unused because we built a new
11051104
// one
11061105
if (IncInstruction->use_empty())

0 commit comments

Comments
 (0)