summaryrefslogtreecommitdiffstats
path: root/clang/include
diff options
context:
space:
mode:
authorJustin Lebar <jlebar@google.com>2016-10-13 18:45:13 +0000
committerJustin Lebar <jlebar@google.com>2016-10-13 18:45:13 +0000
commitaa370bd0d77c136bc6ba87c7b20d007a53e82602 (patch)
tree02c923c7e31bf18513da0488ed0be7403fed2b52 /clang/include
parent179bdce72a4d36abeb9ba6ece8cf312456b92e73 (diff)
downloadbcm5719-llvm-aa370bd0d77c136bc6ba87c7b20d007a53e82602.tar.gz
bcm5719-llvm-aa370bd0d77c136bc6ba87c7b20d007a53e82602.zip
[CUDA] Disallow __shared__ variables in host functions.
Reviewers: tra, rnk Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D25143 llvm-svn: 284144
Diffstat (limited to 'clang/include')
-rw-r--r--clang/include/clang/Basic/DiagnosticSemaKinds.td3
1 files changed, 3 insertions, 0 deletions
diff --git a/clang/include/clang/Basic/DiagnosticSemaKinds.td b/clang/include/clang/Basic/DiagnosticSemaKinds.td
index ff7b3422a94..58029b03039 100644
--- a/clang/include/clang/Basic/DiagnosticSemaKinds.td
+++ b/clang/include/clang/Basic/DiagnosticSemaKinds.td
@@ -6747,6 +6747,9 @@ def err_cuda_vla : Error<
"cannot use variable-length arrays in "
"%select{__device__|__global__|__host__|__host__ __device__}0 functions">;
def err_cuda_extern_shared : Error<"__shared__ variable %0 cannot be 'extern'">;
+def err_cuda_host_shared : Error<
+ "__shared__ local variables not allowed in "
+ "%select{__device__|__global__|__host__|__host__ __device__}0 functions">;
def err_cuda_nonglobal_constant : Error<"__constant__ variables must be global">;
def warn_non_pod_vararg_with_format_string : Warning<
OpenPOWER on IntegriCloud