diff options
author | Alexey Bataev <a.bataev@hotmail.com> | 2019-05-09 18:14:57 +0000 |
---|---|---|
committer | Alexey Bataev <a.bataev@hotmail.com> | 2019-05-09 18:14:57 +0000 |
commit | 41ebe0ce64bfc5ea208fc391b6dabd39bf670cec (patch) | |
tree | 68165d28219aeb3f7e72cd0c432551535546982e /clang/test/OpenMP/report_default_DSA.cpp | |
parent | e406f0eec64f5b6ceb38a2afdd119c41f9905f42 (diff) | |
download | bcm5719-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/report_default_DSA.cpp')
-rw-r--r-- | clang/test/OpenMP/report_default_DSA.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/test/OpenMP/report_default_DSA.cpp b/clang/test/OpenMP/report_default_DSA.cpp index ba620a4ce8e..d6f8158b0e8 100644 --- a/clang/test/OpenMP/report_default_DSA.cpp +++ b/clang/test/OpenMP/report_default_DSA.cpp @@ -7,7 +7,7 @@ void foo(int x, int n) { for (int iter = 0; iter < x; iter++) { #pragma omp target teams distribute parallel for map( \ from \ - : vec [0:n]) default(none) + : vec [0:n]) default(none) // expected-note 4 {{explicit data sharing attribute requested here}} // expected-error@+1 {{variable 'n' must have explicitly specified data sharing attributes}} for (int ii = 0; ii < n; ii++) { // expected-error@+3 {{variable 'iter' must have explicitly specified data sharing attributes}} |