diff options
author | Evgeniy Stepanov <eugeni.stepanov@gmail.com> | 2016-01-20 22:05:50 +0000 |
---|---|---|
committer | Evgeniy Stepanov <eugeni.stepanov@gmail.com> | 2016-01-20 22:05:50 +0000 |
commit | 9fb70f53cee45cf1cfb74070d2aaadcb8434b94b (patch) | |
tree | 2e7493791f7c0a37854aa5ee8ad5c4c668b22db4 /llvm/lib | |
parent | b640415f9bcc3f6c824855199126c53f3488f032 (diff) | |
download | bcm5719-llvm-9fb70f53cee45cf1cfb74070d2aaadcb8434b94b.tar.gz bcm5719-llvm-9fb70f53cee45cf1cfb74070d2aaadcb8434b94b.zip |
Fix PR26152.
Fix the condition for when the new global takes over the name of
the existing one to be the negation of the condition for the new
global to get internal linkage.
llvm-svn: 258355
Diffstat (limited to 'llvm/lib')
-rw-r--r-- | llvm/lib/Linker/IRMover.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/Linker/IRMover.cpp b/llvm/lib/Linker/IRMover.cpp index de368498ef2..9fdf8ca6b24 100644 --- a/llvm/lib/Linker/IRMover.cpp +++ b/llvm/lib/Linker/IRMover.cpp @@ -1087,7 +1087,7 @@ Constant *IRLinker::linkGlobalValueProto(GlobalValue *SGV, bool ForAlias) { return nullptr; NewGV = copyGlobalValueProto(SGV, ShouldLink); - if (!ForAlias) + if (ShouldLink || !ForAlias) forceRenaming(NewGV, SGV->getName()); } if (ShouldLink || ForAlias) { |