adopt getAdjustedAnalysisPointer in a few more passes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@94018 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Chris Lattner
2010-01-20 20:09:02 +00:00
parent fc570e4bff
commit 1bc76d48d4
6 changed files with 64 additions and 0 deletions
+10
View File
@@ -71,6 +71,16 @@ namespace {
AU.setPreservesAll(); // Does not transform code
}
/// getAdjustedAnalysisPointer - This method is used when a pass implements
/// an analysis interface through multiple inheritance. If needed, it
/// should override this to adjust the this pointer as needed for the
/// specified pass info.
virtual void *getAdjustedAnalysisPointer(const PassInfo *PI) {
if (PI->isPassID(&AliasAnalysis::ID))
return (AliasAnalysis*)this;
return this;
}
//------------------------------------------------
// Implement the AliasAnalysis API
//