summaryrefslogtreecommitdiffstats
path: root/clang/test/OpenMP/taskloop_firstprivate_messages.cpp
diff options
context:
space:
mode:
authorAlexey Bataev <a.bataev@hotmail.com>2016-04-13 13:36:48 +0000
committerAlexey Bataev <a.bataev@hotmail.com>2016-04-13 13:36:48 +0000
commit35aaee63cc659f07f0ac5d62e7c87b80cc0f2463 (patch)
tree3be46a1b1141a33e4384aad74dd4ae98a7d46bcd /clang/test/OpenMP/taskloop_firstprivate_messages.cpp
parent11c0b227f5babf37560c0d89538767f985a3f3ee (diff)
downloadbcm5719-llvm-35aaee63cc659f07f0ac5d62e7c87b80cc0f2463.tar.gz
bcm5719-llvm-35aaee63cc659f07f0ac5d62e7c87b80cc0f2463.zip
[OPENMP 4.0] Fixed DSA analysis for taskloop directives.
Patch make clang to perform analysis for task-based directives also for taskloop-based directives. llvm-svn: 266198
Diffstat (limited to 'clang/test/OpenMP/taskloop_firstprivate_messages.cpp')
-rw-r--r--clang/test/OpenMP/taskloop_firstprivate_messages.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/clang/test/OpenMP/taskloop_firstprivate_messages.cpp b/clang/test/OpenMP/taskloop_firstprivate_messages.cpp
index e2e87e4697a..fe22311f650 100644
--- a/clang/test/OpenMP/taskloop_firstprivate_messages.cpp
+++ b/clang/test/OpenMP/taskloop_firstprivate_messages.cpp
@@ -295,9 +295,9 @@ int main(int argc, char **argv) {
#pragma omp taskloop firstprivate(i) // expected-note {{defined as firstprivate}}
for (i = 0; i < argc; ++i) // expected-error {{loop iteration variable in the associated loop of 'omp taskloop' directive may not be firstprivate, predetermined as private}}
foo();
-#pragma omp parallel reduction(+ : i)
-#pragma omp taskloop firstprivate(i) // expected-note {{defined as firstprivate}}
- for (i = 0; i < argc; ++i) // expected-error {{loop iteration variable in the associated loop of 'omp taskloop' directive may not be firstprivate, predetermined as private}}
+#pragma omp parallel reduction(+ : i) // expected-note 4 {{defined as reduction}}
+#pragma omp taskloop firstprivate(i) //expected-error {{argument of a reduction clause of a parallel construct must not appear in a firstprivate clause on a task construct}}
+ for (i = 0; i < argc; ++i) // expected-error 3 {{reduction variables may not be accessed in an explicit task}}
foo();
#pragma omp parallel
#pragma omp taskloop firstprivate(B::x) // expected-error {{threadprivate or thread local variable cannot be firstprivate}}
OpenPOWER on IntegriCloud