From: Sanjay Patel Date: Mon, 17 Aug 2020 18:12:30 +0000 (-0400) Subject: [DAGCombiner] simplify bool return in getStoreMergeCandidates; NFC X-Git-Tag: llvmorg-13-init~14484 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=20c85fd1ab0f064163957a2cf76c20992d514005;p=platform%2Fupstream%2Fllvm.git [DAGCombiner] simplify bool return in getStoreMergeCandidates; NFC --- 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