diff options
author | Anton Korobeynikov <asl@math.spbu.ru> | 2008-09-09 20:05:04 +0000 |
---|---|---|
committer | Anton Korobeynikov <asl@math.spbu.ru> | 2008-09-09 20:05:04 +0000 |
commit | 19e861a4ffb896f16a691d5ac869e894df3cd464 (patch) | |
tree | 70e54c4bb030e963a4d15d45abb8bb48f8447e3f /lib/Transforms/IPO | |
parent | 7ca9d81bce9b3ea6ed2f5e7476a6c4d15c882b2a (diff) | |
download | external_llvm-19e861a4ffb896f16a691d5ac869e894df3cd464.zip external_llvm-19e861a4ffb896f16a691d5ac869e894df3cd464.tar.gz external_llvm-19e861a4ffb896f16a691d5ac869e894df3cd464.tar.bz2 |
Make safer variant of alias resolution routine to be default
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56005 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Transforms/IPO')
-rw-r--r-- | lib/Transforms/IPO/GlobalOpt.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/Transforms/IPO/GlobalOpt.cpp b/lib/Transforms/IPO/GlobalOpt.cpp index 8c6631a..0c059ff 100644 --- a/lib/Transforms/IPO/GlobalOpt.cpp +++ b/lib/Transforms/IPO/GlobalOpt.cpp @@ -2223,7 +2223,7 @@ bool GlobalOpt::ResolveAliases(Module &M) { if (I->use_empty()) continue; - if (const GlobalValue *GV = I->resolveAliasedGlobal(/*traverseWeak*/ false)) + if (const GlobalValue *GV = I->resolveAliasedGlobal()) if (GV != I) { I->replaceAllUsesWith(const_cast<GlobalValue*>(GV)); Changed = true; @@ -2252,7 +2252,6 @@ bool GlobalOpt::runOnModule(Module &M) { // Optimize non-address-taken globals. LocalChange |= OptimizeGlobalVars(M); - Changed |= LocalChange; // Resolve aliases, when possible. LocalChange |= ResolveAliases(M); |