Skip to content

Commit

Permalink
[RISCV] Fix clang-tidy warning about else after return. NFC
Browse files Browse the repository at this point in the history
  • Loading branch information
lukel97 committed Apr 17, 2024
1 parent 37b26bf commit 4536ad4
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion llvm/lib/Target/RISCV/RISCVInsertVSETVLI.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1551,7 +1551,9 @@ void RISCVInsertVSETVLI::doLocalPostpass(MachineBasicBlock &MBB) {
ToDelete.push_back(&MI);
// Leave NextMI unchanged
continue;
} else if (canMutatePriorConfig(MI, *NextMI, Used, *MRI)) {
}

if (canMutatePriorConfig(MI, *NextMI, Used, *MRI)) {
if (!isVLPreservingConfig(*NextMI)) {
MI.getOperand(0).setReg(NextMI->getOperand(0).getReg());
MI.getOperand(0).setIsDead(false);
Expand Down

0 comments on commit 4536ad4

Please sign in to comment.