diff options
author | Mehdi Amini <mehdi.amini@apple.com> | 2016-04-19 16:11:05 +0000 |
---|---|---|
committer | Mehdi Amini <mehdi.amini@apple.com> | 2016-04-19 16:11:05 +0000 |
commit | 113adde594a0caae0ca52d0e5eddb916fc2b0858 (patch) | |
tree | 319e8e487fa590ccc7715dc1a608c853dd16e8ea /llvm/lib/Linker | |
parent | e8b555c6bb93cd3431a18a624bff81020bec2a3b (diff) | |
download | bcm5719-llvm-113adde594a0caae0ca52d0e5eddb916fc2b0858.tar.gz bcm5719-llvm-113adde594a0caae0ca52d0e5eddb916fc2b0858.zip |
ModuleLinker: Do not import linkonce/weak as "external_weak"
Summary:
There is no reason to have a weak reference because the external
definition will be weak.
Reviewers: rafael
Subscribers: llvm-commits, tejohnson
Differential Revision: http://reviews.llvm.org/D19267
From: Mehdi Amini <mehdi.amini@apple.com>
llvm-svn: 266750
Diffstat (limited to 'llvm/lib/Linker')
-rw-r--r-- | llvm/lib/Linker/IRMover.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/llvm/lib/Linker/IRMover.cpp b/llvm/lib/Linker/IRMover.cpp index 5b52ea8106e..81858bd421f 100644 --- a/llvm/lib/Linker/IRMover.cpp +++ b/llvm/lib/Linker/IRMover.cpp @@ -617,8 +617,7 @@ GlobalValue *IRLinker::copyGlobalValueProto(const GlobalValue *SGV, if (ForDefinition) NewGV->setLinkage(SGV->getLinkage()); - else if (SGV->hasExternalWeakLinkage() || SGV->hasWeakLinkage() || - SGV->hasLinkOnceLinkage()) + else if (SGV->hasExternalWeakLinkage()) NewGV->setLinkage(GlobalValue::ExternalWeakLinkage); NewGV->copyAttributesFrom(SGV); |