summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/SelectionDAG
diff options
context:
space:
mode:
authorCraig Topper <craig.topper@gmail.com>2017-04-06 04:02:28 +0000
committerCraig Topper <craig.topper@gmail.com>2017-04-06 04:02:28 +0000
commitfaf5a8553c024e42e2eb08ef02829146a4a9094d (patch)
tree2f10a1d9f6db224b349e1a9bb63cbde7d544370e /llvm/lib/CodeGen/SelectionDAG
parent0d622a4bf9035bfd55c29b511c5acd2d23ea62ad (diff)
downloadbcm5719-llvm-faf5a8553c024e42e2eb08ef02829146a4a9094d.tar.gz
bcm5719-llvm-faf5a8553c024e42e2eb08ef02829146a4a9094d.zip
foo
llvm-svn: 299618
Diffstat (limited to 'llvm/lib/CodeGen/SelectionDAG')
-rw-r--r--llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp b/llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp
index d3ccdcd5ffd..753e5281bfc 100644
--- a/llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp
+++ b/llvm/lib/CodeGen/SelectionDAG/TargetLowering.cpp
@@ -791,6 +791,9 @@ bool TargetLowering::SimplifyDemandedBits(SDValue Op,
// TODO: Should we check for other forms of sign-bit comparisons?
// Examples: X <= -1, X >= 0
}
+ if (getBooleanContents(Op.getOperand(0).getValueType()) ==
+ BooleanContent::ZeroOrOneBooleanContent && BitWidth > 1)
+ KnownZero.setBitsFrom(1);
break;
}
case ISD::SHL:
OpenPOWER on IntegriCloud