[llvm-branch-commits] [llvm] 2c2d489 - [CodeGen] Remove unused function isRegLiveInExitBlocks (NFC)
Kazu Hirata via llvm-branch-commits
llvm-branch-commits at lists.llvm.org
Tue Jan 12 21:48:53 PST 2021
Author: Kazu Hirata
Date: 2021-01-12T21:43:48-08:00
New Revision: 2c2d489b78c43072b65f3d8c88c91def4c69f320
URL: https://github.com/llvm/llvm-project/commit/2c2d489b78c43072b65f3d8c88c91def4c69f320
DIFF: https://github.com/llvm/llvm-project/commit/2c2d489b78c43072b65f3d8c88c91def4c69f320.diff
LOG: [CodeGen] Remove unused function isRegLiveInExitBlocks (NFC)
The last use was removed on Jan 17, 2020 in commit
42350cd893a9cf6c199b17441dc2ba526c7cca71.
Added:
Modified:
llvm/include/llvm/CodeGen/MachineLoopUtils.h
llvm/lib/CodeGen/MachineLoopUtils.cpp
Removed:
################################################################################
diff --git a/llvm/include/llvm/CodeGen/MachineLoopUtils.h b/llvm/include/llvm/CodeGen/MachineLoopUtils.h
index 2cb0134ca848..ec0b3529c0d6 100644
--- a/llvm/include/llvm/CodeGen/MachineLoopUtils.h
+++ b/llvm/include/llvm/CodeGen/MachineLoopUtils.h
@@ -37,10 +37,6 @@ MachineBasicBlock *PeelSingleBlockLoop(LoopPeelDirection Direction,
MachineRegisterInfo &MRI,
const TargetInstrInfo *TII);
-/// Return true if PhysReg is live outside the loop, i.e. determine if it
-/// is live in the loop exit blocks, and false otherwise.
-bool isRegLiveInExitBlocks(MachineLoop *Loop, int PhysReg);
-
} // namespace llvm
#endif // LLVM_LIB_CODEGEN_MACHINELOOPUTILS_H
diff --git a/llvm/lib/CodeGen/MachineLoopUtils.cpp b/llvm/lib/CodeGen/MachineLoopUtils.cpp
index 2295e1ca6d4e..fdcc8472f1c2 100644
--- a/llvm/lib/CodeGen/MachineLoopUtils.cpp
+++ b/llvm/lib/CodeGen/MachineLoopUtils.cpp
@@ -130,14 +130,3 @@ MachineBasicBlock *llvm::PeelSingleBlockLoop(LoopPeelDirection Direction,
return NewBB;
}
-
-bool llvm::isRegLiveInExitBlocks(MachineLoop *Loop, int PhysReg) {
- SmallVector<MachineBasicBlock *, 4> ExitBlocks;
- Loop->getExitBlocks(ExitBlocks);
-
- for (auto *MBB : ExitBlocks)
- if (MBB->isLiveIn(PhysReg))
- return true;
-
- return false;
-}
More information about the llvm-branch-commits
mailing list