mirror of
https://github.com/RPCSX/llvm.git
synced 2025-01-26 22:45:05 +00:00
Avoid to assert on "(KnownZero & KnownOne) == 0".
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@35062 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
430f626937
commit
edd089c86a
@ -979,7 +979,7 @@ static bool MaskedValueIsZero(Value *V, uint64_t Mask, unsigned Depth = 0) {
|
||||
/// this predicate to simplify operations downstream. Mask is known to be zero
|
||||
/// for bits that V cannot have.
|
||||
static bool MaskedValueIsZero(Value *V, const APInt& Mask, unsigned Depth = 0) {
|
||||
APInt KnownZero(Mask), KnownOne(Mask);
|
||||
APInt KnownZero(Mask.getBitWidth(), 0), KnownOne(Mask.getBitWidth(), 0);
|
||||
ComputeMaskedBits(V, Mask, KnownZero, KnownOne, Depth);
|
||||
assert((KnownZero & KnownOne) == 0 && "Bits known to be one AND zero?");
|
||||
return (KnownZero & Mask) == Mask;
|
||||
|
Loading…
x
Reference in New Issue
Block a user