summaryrefslogtreecommitdiffstats
path: root/llvm/include
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2011-04-09 05:51:34 +0000
committerChris Lattner <sabre@nondot.org>2011-04-09 05:51:34 +0000
commit2bd7015de5ee17522661cf35d1db66eb5fd67a56 (patch)
treeeffe3b4dd613019fd16da0e316c773d0912167e4 /llvm/include
parent9cb59fa8346608a6663acbc03ff82a5e61427117 (diff)
downloadbcm5719-llvm-2bd7015de5ee17522661cf35d1db66eb5fd67a56.tar.gz
bcm5719-llvm-2bd7015de5ee17522661cf35d1db66eb5fd67a56.zip
fix a potentially serious bug in AliasSet::removeCallSite
where we shrunk the list without updating the end iterator. By inspection, from PR9639. llvm-svn: 129190
Diffstat (limited to 'llvm/include')
-rw-r--r--llvm/include/llvm/Analysis/AliasSetTracker.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/llvm/include/llvm/Analysis/AliasSetTracker.h b/llvm/include/llvm/Analysis/AliasSetTracker.h
index e844d10dda0..4efa3963b66 100644
--- a/llvm/include/llvm/Analysis/AliasSetTracker.h
+++ b/llvm/include/llvm/Analysis/AliasSetTracker.h
@@ -259,6 +259,7 @@ private:
if (CallSites[i] == CS.getInstruction()) {
CallSites[i] = CallSites.back();
CallSites.pop_back();
+ --i; --e; // Revisit the moved entry.
}
}
void setVolatile() { Volatile = true; }
OpenPOWER on IntegriCloud