diff options
author | Rafael Espindola <rafael.espindola@gmail.com> | 2012-04-04 12:51:34 +0000 |
---|---|---|
committer | Rafael Espindola <rafael.espindola@gmail.com> | 2012-04-04 12:51:34 +0000 |
commit | 26c8dcc692fb2addd475446cfff24d6a4e958bca (patch) | |
tree | b71cb0d781e2735397c728f276f14ea63780d04c /include/llvm/Analysis/ValueTracking.h | |
parent | 00b73a5e443d49d68f59a5fb517e940842423ae6 (diff) | |
download | llvm-26c8dcc692fb2addd475446cfff24d6a4e958bca.tar.gz llvm-26c8dcc692fb2addd475446cfff24d6a4e958bca.tar.bz2 llvm-26c8dcc692fb2addd475446cfff24d6a4e958bca.tar.xz |
Always compute all the bits in ComputeMaskedBits.
This allows us to keep passing reduced masks to SimplifyDemandedBits, but
know about all the bits if SimplifyDemandedBits fails. This allows instcombine
to simplify cases like the one in the included testcase.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@154011 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/Analysis/ValueTracking.h')
-rw-r--r-- | include/llvm/Analysis/ValueTracking.h | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/include/llvm/Analysis/ValueTracking.h b/include/llvm/Analysis/ValueTracking.h index 68ea8a105d..f2f9db4ce4 100644 --- a/include/llvm/Analysis/ValueTracking.h +++ b/include/llvm/Analysis/ValueTracking.h @@ -36,11 +36,9 @@ namespace llvm { /// where V is a vector, the mask, known zero, and known one values are the /// same width as the vector element, and the bit is set only if it is true /// for all of the elements in the vector. - void ComputeMaskedBits(Value *V, const APInt &Mask, APInt &KnownZero, - APInt &KnownOne, const TargetData *TD = 0, - unsigned Depth = 0); - void computeMaskedBitsLoad(const MDNode &Ranges, const APInt &Mask, - APInt &KnownZero); + void ComputeMaskedBits(Value *V, APInt &KnownZero, APInt &KnownOne, + const TargetData *TD = 0, unsigned Depth = 0); + void computeMaskedBitsLoad(const MDNode &Ranges, APInt &KnownZero); /// ComputeSignBit - Determine whether the sign bit is known to be zero or /// one. Convenience wrapper around ComputeMaskedBits. |