summaryrefslogtreecommitdiffstats
path: root/llvm/lib/MC/MCAsmInfo.cpp
diff options
context:
space:
mode:
authorJingyue Wu <jingyue@google.com>2014-12-01 21:16:17 +0000
committerJingyue Wu <jingyue@google.com>2014-12-01 21:16:17 +0000
commit5b62eb9b4845c3e88c5a2f467084c323106df7b6 (patch)
tree9aa13ec0afd91f29c4b415f73e1e7c2a17d820d9 /llvm/lib/MC/MCAsmInfo.cpp
parent35fc363ce8f04c7a74ce3848ce25d90b1a5bd556 (diff)
downloadbcm5719-llvm-5b62eb9b4845c3e88c5a2f467084c323106df7b6.tar.gz
bcm5719-llvm-5b62eb9b4845c3e88c5a2f467084c323106df7b6.zip
[NVPTX] Do not emit .weak symbols for NVPTX
Summary: ".weak" symbols cannot be consumed by ptxas (PR21685). This patch makes the weak directive in MCAsmPrinter customizable, and disables emitting ".weak" symbols for NVPTX. Test Plan: weak-linkage.ll Reviewers: jholewinski Reviewed By: jholewinski Subscribers: majnemer, jholewinski, llvm-commits Differential Revision: http://reviews.llvm.org/D6455 llvm-svn: 223077
Diffstat (limited to 'llvm/lib/MC/MCAsmInfo.cpp')
-rw-r--r--llvm/lib/MC/MCAsmInfo.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/llvm/lib/MC/MCAsmInfo.cpp b/llvm/lib/MC/MCAsmInfo.cpp
index 2fb558f1f3e..053061823ff 100644
--- a/llvm/lib/MC/MCAsmInfo.cpp
+++ b/llvm/lib/MC/MCAsmInfo.cpp
@@ -71,6 +71,7 @@ MCAsmInfo::MCAsmInfo() {
HasSingleParameterDotFile = true;
HasIdentDirective = false;
HasNoDeadStrip = false;
+ WeakDirective = "\t.weak\t";
WeakRefDirective = nullptr;
HasWeakDefDirective = false;
HasWeakDefCanBeHiddenDirective = false;
OpenPOWER on IntegriCloud