This transform also applies to private linkage.
authorDuncan Sands <baldrick@free.fr>
Tue, 17 Feb 2009 17:50:04 +0000 (17:50 +0000)
committerDuncan Sands <baldrick@free.fr>
Tue, 17 Feb 2009 17:50:04 +0000 (17:50 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@64773 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Transforms/IPO/GlobalOpt.cpp

index b60982919e4e349b521fbcfa2e39636270633483..0ac1e65891b7962b102096b6222c288c7f5c9840 100644 (file)
@@ -2398,11 +2398,11 @@ bool GlobalOpt::ResolveAliases(Module &M) {
     //   @a = alias ... @f
     // into:
     //   define ... @a(...)
-    if (!Target->hasInternalLinkage())
+    if (!Target->hasLocalLinkage())
       continue;
 
     // The transform is only useful if the alias does not have internal linkage.
-    if (J->hasInternalLinkage())
+    if (J->hasLocalLinkage())
       continue;
 
     // Do not perform the transform if multiple aliases potentially target the