diff options
author | Rafael Espindola <rafael.espindola@gmail.com> | 2014-03-26 06:14:40 +0000 |
---|---|---|
committer | Rafael Espindola <rafael.espindola@gmail.com> | 2014-03-26 06:14:40 +0000 |
commit | 72db10a9959431a710712f64d4b98299ab5a022d (patch) | |
tree | 8ea039520d3cec3f1adcf367c2a6915744f6a559 /lib/IR/Verifier.cpp | |
parent | 360ee971798ebccc177f7e1c2947a74e3bd9fbc0 (diff) | |
download | llvm-72db10a9959431a710712f64d4b98299ab5a022d.tar.gz llvm-72db10a9959431a710712f64d4b98299ab5a022d.tar.bz2 llvm-72db10a9959431a710712f64d4b98299ab5a022d.tar.xz |
Revert "Prevent alias from pointing to weak aliases."
This reverts commit r204781.
I will follow up to with msan folks to see what is what they
were trying to do with aliases to weak aliases.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204784 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/IR/Verifier.cpp')
-rw-r--r-- | lib/IR/Verifier.cpp | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/lib/IR/Verifier.cpp b/lib/IR/Verifier.cpp index f5c8ac623b..50c6ae204e 100644 --- a/lib/IR/Verifier.cpp +++ b/lib/IR/Verifier.cpp @@ -502,14 +502,10 @@ void Verifier::visitGlobalAlias(const GlobalAlias &GA) { } } Assert1(!GV->isDeclaration(), "Alias must point to a definition", &GA); - if (const GlobalAlias *GAAliasee = dyn_cast<GlobalAlias>(GV)) { - Assert1(!GAAliasee->mayBeOverridden(), "Alias cannot point to a weak alias", - &GA); - } - const GlobalValue *AG = GA.getAliasedGlobal(); - Assert1(AG, "Aliasing chain should end with function or global variable", - &GA); + const GlobalValue* Resolved = GA.resolveAliasedGlobal(/*stopOnWeak*/ false); + Assert1(Resolved, + "Aliasing chain should end with function or global variable", &GA); visitGlobalValue(GA); } |