aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenjamin Kramer <benny.kra@googlemail.com>2012-10-05 18:19:44 +0000
committerBenjamin Kramer <benny.kra@googlemail.com>2012-10-05 18:19:44 +0000
commit62f7fb977c6ff967c3a40e3dd4e93f33aeb8b219 (patch)
tree5faf5eee6f66257f62784774d10a17e7712f0e01
parent28326d8e1d85574b8cf951913cb7d484efd97a9f (diff)
downloadllvm-62f7fb977c6ff967c3a40e3dd4e93f33aeb8b219.zip
llvm-62f7fb977c6ff967c3a40e3dd4e93f33aeb8b219.tar.gz
llvm-62f7fb977c6ff967c3a40e3dd4e93f33aeb8b219.tar.bz2
Simplify code, don't or a bool with an uint64_t.
No functionality change. llvm-svn: 165321
-rw-r--r--llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp b/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
index 0f8b499..a5eccae 100644
--- a/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
+++ b/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
@@ -7577,9 +7577,9 @@ bool DAGCombiner::MergeConsecutiveStores(StoreSDNode* St) {
SDValue StoredVal = St->getValue();
if (ConstantSDNode *C = dyn_cast<ConstantSDNode>(StoredVal)) {
- NonZero |= (C->getZExtValue() != 0);
+ NonZero |= !C->isNullValue();
} else if (ConstantFPSDNode *C = dyn_cast<ConstantFPSDNode>(StoredVal)) {
- NonZero |= C->getValueAPF().bitcastToAPInt().getZExtValue();
+ NonZero |= !C->getConstantFPValue()->isNullValue();
} else {
// Non constant.
break;