projects
/
platform
/
upstream
/
llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d687858
)
[ValueTracking] Use BitWidth local variable instead of re-reading it from KnownZero...
author
Craig Topper
<craig.topper@gmail.com>
Tue, 25 Apr 2017 16:48:03 +0000
(16:48 +0000)
committer
Craig Topper
<craig.topper@gmail.com>
Tue, 25 Apr 2017 16:48:03 +0000
(16:48 +0000)
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
llvm/lib/Analysis/ValueTracking.cpp
patch
|
blob
|
history
diff --git
a/llvm/lib/Analysis/ValueTracking.cpp
b/llvm/lib/Analysis/ValueTracking.cpp
index
e2ffa44
..
ecb169c
100644
(file)
--- 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;