]> granicus.if.org Git - clang/commit
[CUDA] Do not merge CUDA target attributes.
authorArtem Belevich <tra@google.com>
Tue, 13 Sep 2016 22:16:30 +0000 (22:16 +0000)
committerArtem Belevich <tra@google.com>
Tue, 13 Sep 2016 22:16:30 +0000 (22:16 +0000)
commit19ed54635a3a99cc6d81e5091f12d481ff44b548
treeb76182773b2a84ddc7ee7c3d79bfe086be9efdd6
parent7d009710999be64cdb3527c92ec8ab74c4d98c6a
[CUDA] Do not merge CUDA target attributes.

CUDA target attributes are used for function overloading and must not be merged.

This fixes a bug where attributes were inherited during function template
specialization in CUDA and made it impossible for specialized function
to provide its own target attributes.

Differential Revision: https://reviews.llvm.org/D24522

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@281406 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Sema/SemaDecl.cpp
test/SemaCUDA/function-overload.cu
test/SemaCUDA/target_attr_inheritance.cu [new file with mode: 0644]