Add helper for ultimate aliasee resoltion

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48255 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Anton Korobeynikov
2008-03-11 22:28:56 +00:00
parent 7db30ba701
commit e846dd89c1
2 changed files with 22 additions and 1 deletions

View File

@@ -78,7 +78,12 @@ public:
/// getAliasedGlobal() - Aliasee can be either global or bitcast of
/// global. This method retrives the global for both aliasee flavours.
const GlobalValue* getAliasedGlobal() const;
/// resolveAliasedGlobal() - This method tries to ultimately resolve alias by
/// going through aliasing chain and trying to find the very last
/// global. Return NULL is cycle was found.
const GlobalValue* resolveAliasedGlobal() const;
// Methods for support type inquiry through isa, cast, and dyn_cast:
static inline bool classof(const GlobalAlias *) { return true; }
static inline bool classof(const Value *V) {