aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/CodeGen/BranchFolding.cpp
diff options
context:
space:
mode:
authorKazu Hirata <kazu@google.com>2021-09-10 11:11:31 -0700
committerKazu Hirata <kazu@google.com>2021-09-10 11:11:31 -0700
commitc9fca53af10eca9a0ce0e32f553b3b6eb4f0fba6 (patch)
treef6a40c0590efed1a0f9408d813795339ff51fd2f /llvm/lib/CodeGen/BranchFolding.cpp
parent03df97101287e8cb647c6c0982c4efdb82585c21 (diff)
downloadllvm-c9fca53af10eca9a0ce0e32f553b3b6eb4f0fba6.zip
llvm-c9fca53af10eca9a0ce0e32f553b3b6eb4f0fba6.tar.gz
llvm-c9fca53af10eca9a0ce0e32f553b3b6eb4f0fba6.tar.bz2
[CodeGen, Target] Use pred_empty and succ_empty (NFC)
Diffstat (limited to 'llvm/lib/CodeGen/BranchFolding.cpp')
-rw-r--r--llvm/lib/CodeGen/BranchFolding.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/BranchFolding.cpp b/llvm/lib/CodeGen/BranchFolding.cpp
index 65e7e92..1638562 100644
--- a/llvm/lib/CodeGen/BranchFolding.cpp
+++ b/llvm/lib/CodeGen/BranchFolding.cpp
@@ -611,7 +611,7 @@ ProfitableToMerge(MachineBasicBlock *MBB1, MachineBasicBlock *MBB2,
// there are fallthroughs, and we don't know until after layout.
if (AfterPlacement && FullBlockTail1 && FullBlockTail2) {
auto BothFallThrough = [](MachineBasicBlock *MBB) {
- if (MBB->succ_size() != 0 && !MBB->canFallThrough())
+ if (!MBB->succ_empty() && !MBB->canFallThrough())
return false;
MachineFunction::iterator I(MBB);
MachineFunction *MF = MBB->getParent();