From 2b14b80b6043650d259b85e419f2c80f97c4f1e3 Mon Sep 17 00:00:00 2001 From: Rafael Espindola Date: Mon, 26 Dec 2011 23:12:42 +0000 Subject: Fix warning. llvm-svn: 147284 --- llvm/lib/Transforms/Scalar/ScalarReplAggregates.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'llvm/lib/Transforms') diff --git a/llvm/lib/Transforms/Scalar/ScalarReplAggregates.cpp b/llvm/lib/Transforms/Scalar/ScalarReplAggregates.cpp index bc70c51cc01..43d56ef0997 100644 --- a/llvm/lib/Transforms/Scalar/ScalarReplAggregates.cpp +++ b/llvm/lib/Transforms/Scalar/ScalarReplAggregates.cpp @@ -938,13 +938,14 @@ public: void run(AllocaInst *AI, const SmallVectorImpl &Insts) { // Remember which alloca we're promoting (for isInstInList). this->AI = AI; - if (MDNode *DebugNode = MDNode::getIfExists(AI->getContext(), AI)) + if (MDNode *DebugNode = MDNode::getIfExists(AI->getContext(), AI)) { for (Value::use_iterator UI = DebugNode->use_begin(), E = DebugNode->use_end(); UI != E; ++UI) if (DbgDeclareInst *DDI = dyn_cast(*UI)) DDIs.push_back(DDI); else if (DbgValueInst *DVI = dyn_cast(*UI)) DVIs.push_back(DVI); + } LoadAndStorePromoter::run(Insts); AI->eraseFromParent(); -- cgit v1.2.3