[llvm] 76843ba - [Attributor][Fix] Initialize unused but loaded variable
Johannes Doerfert via llvm-commits
llvm-commits at lists.llvm.org
Tue Jan 28 21:52:58 PST 2020
Author: Johannes Doerfert
Date: 2020-01-28T23:52:16-06:00
New Revision: 76843ba37f0b69c01a6bcc61123cadfec0164855
URL: https://github.com/llvm/llvm-project/commit/76843ba37f0b69c01a6bcc61123cadfec0164855
DIFF: https://github.com/llvm/llvm-project/commit/76843ba37f0b69c01a6bcc61123cadfec0164855.diff
LOG: [Attributor][Fix] Initialize unused but loaded variable
This hopefully un-breaks:
http://lab.llvm.org:8011/builders/sanitizer-x86_64-linux-fast/builds/38333
Added:
Modified:
llvm/lib/Transforms/IPO/Attributor.cpp
Removed:
################################################################################
diff --git a/llvm/lib/Transforms/IPO/Attributor.cpp b/llvm/lib/Transforms/IPO/Attributor.cpp
index 9821d9e28220..64238ca58771 100644
--- a/llvm/lib/Transforms/IPO/Attributor.cpp
+++ b/llvm/lib/Transforms/IPO/Attributor.cpp
@@ -4460,7 +4460,7 @@ struct AAValueSimplifyFloating : AAValueSimplifyImpl {
ChangeStatus updateImpl(Attributor &A) override {
bool HasValueBefore = SimplifiedAssociatedValue.hasValue();
- auto VisitValueCB = [&](Value &V, bool, bool Stripped) -> bool {
+ auto VisitValueCB = [&](Value &V, bool &, bool Stripped) -> bool {
auto &AA = A.getAAFor<AAValueSimplify>(*this, IRPosition::value(V));
if (!Stripped && this == &AA) {
// TODO: Look the instruction and check recursively.
@@ -4472,7 +4472,7 @@ struct AAValueSimplifyFloating : AAValueSimplifyImpl {
return checkAndUpdate(A, *this, V, SimplifiedAssociatedValue);
};
- bool Dummy;
+ bool Dummy = false;
if (!genericValueTraversal<AAValueSimplify, bool>(A, getIRPosition(), *this,
Dummy, VisitValueCB))
if (!askSimplifiedValueForAAValueConstantRange(A))
More information about the llvm-commits
mailing list