diff options
| author | Rafael Espindola <rafael.espindola@gmail.com> | 2012-12-13 03:37:24 +0000 |
|---|---|---|
| committer | Rafael Espindola <rafael.espindola@gmail.com> | 2012-12-13 03:37:24 +0000 |
| commit | 319f74cd11042e0ee0bbe0daaac465cc393a58e3 (patch) | |
| tree | 9cdd3aad050bfbb89f16faad29bf3b7b9efb4965 /llvm/lib/Analysis/InstructionSimplify.cpp | |
| parent | cf9a61b6eeb12d647b484cbc6eb09d4ca1ca8bb0 (diff) | |
| download | bcm5719-llvm-319f74cd11042e0ee0bbe0daaac465cc393a58e3.tar.gz bcm5719-llvm-319f74cd11042e0ee0bbe0daaac465cc393a58e3.zip | |
Rename isPowerOfTwo to isKnownToBeAPowerOfTwo.
In a previous thread it was pointed out that isPowerOfTwo is not a very precise
name since it can return false for powers of two if it is unable to show that
they are powers of two.
llvm-svn: 170093
Diffstat (limited to 'llvm/lib/Analysis/InstructionSimplify.cpp')
| -rw-r--r-- | llvm/lib/Analysis/InstructionSimplify.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/Analysis/InstructionSimplify.cpp b/llvm/lib/Analysis/InstructionSimplify.cpp index 2bcd3633cf1..0b88f457627 100644 --- a/llvm/lib/Analysis/InstructionSimplify.cpp +++ b/llvm/lib/Analysis/InstructionSimplify.cpp @@ -1457,9 +1457,9 @@ static Value *SimplifyAndInst(Value *Op0, Value *Op1, const Query &Q, // A & (-A) = A if A is a power of two or zero. if (match(Op0, m_Neg(m_Specific(Op1))) || match(Op1, m_Neg(m_Specific(Op0)))) { - if (isPowerOfTwo(Op0, /*OrZero*/true)) + if (isKnownToBeAPowerOfTwo(Op0, /*OrZero*/true)) return Op0; - if (isPowerOfTwo(Op1, /*OrZero*/true)) + if (isKnownToBeAPowerOfTwo(Op1, /*OrZero*/true)) return Op1; } |

