diff options
author | Artem Belevich <tra@google.com> | 2015-09-23 17:44:53 +0000 |
---|---|---|
committer | Artem Belevich <tra@google.com> | 2015-09-23 17:44:53 +0000 |
commit | 7b41f70e6c323615d54ce5058220214c46279add (patch) | |
tree | 85f22f8bd0309eef236e376142df8bc1f6e4fb0c /clang/lib/Sema/SemaDeclAttr.cpp | |
parent | ade3abd2d9fa3465718cb4baeaf535de39fa6161 (diff) | |
download | bcm5719-llvm-7b41f70e6c323615d54ce5058220214c46279add.tar.gz bcm5719-llvm-7b41f70e6c323615d54ce5058220214c46279add.zip |
[CUDA] __global__ functions should always be visible externally.
Adjust __global__ functions with DiscardableODR linkage to use
StrongODR linkage instead, so they are visible externally.
Differential Revision: http://reviews.llvm.org/D13067
llvm-svn: 248400
Diffstat (limited to 'clang/lib/Sema/SemaDeclAttr.cpp')
-rw-r--r-- | clang/lib/Sema/SemaDeclAttr.cpp | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/clang/lib/Sema/SemaDeclAttr.cpp b/clang/lib/Sema/SemaDeclAttr.cpp index ddf189ae12c..9cc082152bb 100644 --- a/clang/lib/Sema/SemaDeclAttr.cpp +++ b/clang/lib/Sema/SemaDeclAttr.cpp @@ -3351,9 +3351,6 @@ static void handleGlobalAttr(Sema &S, Decl *D, const AttributeList &Attr) { CUDAGlobalAttr(Attr.getRange(), S.Context, Attr.getAttributeSpellingListIndex())); - // Add implicit attribute((used)) so we don't eliminate kernels - // because there is nothing referencing them on device side. - D->addAttr(UsedAttr::CreateImplicit(S.Context)); } static void handleGNUInlineAttr(Sema &S, Decl *D, const AttributeList &Attr) { |