aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
diff options
context:
space:
mode:
authorSanjay Patel <spatel@rotateright.com>2020-08-17 14:12:30 -0400
committerSanjay Patel <spatel@rotateright.com>2020-08-17 15:37:55 -0400
commit20c85fd1ab0f064163957a2cf76c20992d514005 (patch)
treebde7ef0874441a32b44716e79e9d2a2a65f05b42 /llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
parent52cd8f1ecb234c3268b0e0e8c73cdad5c02d29e5 (diff)
downloadllvm-20c85fd1ab0f064163957a2cf76c20992d514005.zip
llvm-20c85fd1ab0f064163957a2cf76c20992d514005.tar.gz
llvm-20c85fd1ab0f064163957a2cf76c20992d514005.tar.bz2
[DAGCombiner] simplify bool return in getStoreMergeCandidates; NFC
Diffstat (limited to 'llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp')
-rw-r--r--llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp10
1 files changed, 4 insertions, 6 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp b/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
index 0b2e918..8ad19e7 100644
--- a/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
+++ b/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
@@ -16133,7 +16133,7 @@ void DAGCombiner::getStoreMergeCandidates(
int64_t &Offset) -> bool {
// The memory operands must not be volatile/indexed/atomic.
// TODO: May be able to relax for unordered atomics (see D66309)
- if (!Other->isSimple() || Other->isIndexed())
+ if (!Other->isSimple() || Other->isIndexed())
return false;
// Don't mix temporal stores with non-temporal stores.
if (St->isNonTemporal() != Other->isNonTemporal())
@@ -16195,11 +16195,9 @@ void DAGCombiner::getStoreMergeCandidates(
auto OverLimitInDependenceCheck = [&](SDNode *StoreNode,
SDNode *RootNode) -> bool {
auto RootCount = StoreRootCountMap.find(StoreNode);
- if (RootCount != StoreRootCountMap.end() &&
- RootCount->second.first == RootNode &&
- RootCount->second.second > StoreMergeDependenceLimit)
- return true;
- return false;
+ return RootCount != StoreRootCountMap.end() &&
+ RootCount->second.first == RootNode &&
+ RootCount->second.second > StoreMergeDependenceLimit;
};
// We looking for a root node which is an ancestor to all mergable