summaryrefslogtreecommitdiffstats
path: root/clang/test/OpenMP/distribute_parallel_for_default_messages.cpp
diff options
context:
space:
mode:
authorAlexey Bataev <a.bataev@hotmail.com>2019-05-09 18:14:57 +0000
committerAlexey Bataev <a.bataev@hotmail.com>2019-05-09 18:14:57 +0000
commit41ebe0ce64bfc5ea208fc391b6dabd39bf670cec (patch)
tree68165d28219aeb3f7e72cd0c432551535546982e /clang/test/OpenMP/distribute_parallel_for_default_messages.cpp
parente406f0eec64f5b6ceb38a2afdd119c41f9905f42 (diff)
downloadbcm5719-llvm-41ebe0ce64bfc5ea208fc391b6dabd39bf670cec.tar.gz
bcm5719-llvm-41ebe0ce64bfc5ea208fc391b6dabd39bf670cec.zip
[OPENMP]Fix PR41768: check DSA for globals with default(none) clauses.
If the default(none) was specified for the construct, we might miss diagnostic for the globals without explicitly specified data-sharing attributes. Patch fixes this problem. llvm-svn: 360362
Diffstat (limited to 'clang/test/OpenMP/distribute_parallel_for_default_messages.cpp')
-rw-r--r--clang/test/OpenMP/distribute_parallel_for_default_messages.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/clang/test/OpenMP/distribute_parallel_for_default_messages.cpp b/clang/test/OpenMP/distribute_parallel_for_default_messages.cpp
index cb9cbcf6ba4..19042ef8a55 100644
--- a/clang/test/OpenMP/distribute_parallel_for_default_messages.cpp
+++ b/clang/test/OpenMP/distribute_parallel_for_default_messages.cpp
@@ -24,7 +24,7 @@ T tmain(T argc) {
foo();
#pragma omp target
#pragma omp teams
-#pragma omp distribute parallel for default(none // expected-error {{expected ')'}} expected-note {{to match this '('}}
+#pragma omp distribute parallel for default(none // expected-error {{expected ')'}} expected-note {{to match this '('}} expected-note 2 {{explicit data sharing attribute requested here}}
for (i = 0; i < argc; ++i) // expected-error 2 {{variable 'argc' must have explicitly specified data sharing attributes}}
foo();
#pragma omp target
@@ -39,7 +39,7 @@ T tmain(T argc) {
foo();
#pragma omp target
#pragma omp teams
-#pragma omp distribute parallel for default(none)
+#pragma omp distribute parallel for default(none) // expected-note 2 {{explicit data sharing attribute requested here}}
for (i = 0; i < argc; ++i) // expected-error 2 {{variable 'argc' must have explicitly specified data sharing attributes}}
foo();
@@ -72,7 +72,7 @@ int main(int argc, char **argv) {
foo();
#pragma omp target
#pragma omp teams
-#pragma omp distribute parallel for default(none // expected-error {{expected ')'}} expected-note {{to match this '('}}
+#pragma omp distribute parallel for default(none // expected-error {{expected ')'}} expected-note {{to match this '('}} expected-note {{explicit data sharing attribute requested here}}
for (i = 0; i < argc; ++i) // expected-error {{variable 'argc' must have explicitly specified data sharing attributes}}
foo();
#pragma omp target
@@ -87,7 +87,7 @@ int main(int argc, char **argv) {
foo();
#pragma omp target
#pragma omp teams
-#pragma omp distribute parallel for default(none)
+#pragma omp distribute parallel for default(none) // expected-note {{explicit data sharing attribute requested here}}
for (i = 0; i < argc; ++i) // expected-error {{variable 'argc' must have explicitly specified data sharing attributes}}
foo();
OpenPOWER on IntegriCloud