summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Analysis/ValueTracking.cpp
diff options
context:
space:
mode:
authorCraig Topper <craig.topper@gmail.com>2017-04-25 16:48:03 +0000
committerCraig Topper <craig.topper@gmail.com>2017-04-25 16:48:03 +0000
commit9c932d31e11f45afde50fd21b47cbf744ff69356 (patch)
treeab0ca531d5854fd15b2539adedbbc413e9d683a4 /llvm/lib/Analysis/ValueTracking.cpp
parentd68785803b0603209c9af0d2353e79131a59c498 (diff)
downloadbcm5719-llvm-9c932d31e11f45afde50fd21b47cbf744ff69356.tar.gz
bcm5719-llvm-9c932d31e11f45afde50fd21b47cbf744ff69356.zip
[ValueTracking] Use BitWidth local variable instead of re-reading it from KnownZero. NFC
This is a pre-commit for a patch that I'm working on to merge KnownZero/KnownOne into a KnownBits struct which would have had to touch this line. llvm-svn: 301323
Diffstat (limited to 'llvm/lib/Analysis/ValueTracking.cpp')
-rw-r--r--llvm/lib/Analysis/ValueTracking.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/Analysis/ValueTracking.cpp b/llvm/lib/Analysis/ValueTracking.cpp
index e2ffa440c90..ecb169cb0db 100644
--- a/llvm/lib/Analysis/ValueTracking.cpp
+++ b/llvm/lib/Analysis/ValueTracking.cpp
@@ -1532,7 +1532,7 @@ void computeKnownBits(const Value *V, APInt &KnownZero, APInt &KnownOne,
// We know that CDS must be a vector of integers. Take the intersection of
// each element.
KnownZero.setAllBits(); KnownOne.setAllBits();
- APInt Elt(KnownZero.getBitWidth(), 0);
+ APInt Elt(BitWidth, 0);
for (unsigned i = 0, e = CDS->getNumElements(); i != e; ++i) {
Elt = CDS->getElementAsInteger(i);
KnownZero &= ~Elt;
OpenPOWER on IntegriCloud