summaryrefslogtreecommitdiffstats
path: root/clang/lib/Basic
diff options
context:
space:
mode:
authorAlexey Bataev <a.bataev@hotmail.com>2014-07-08 08:12:03 +0000
committerAlexey Bataev <a.bataev@hotmail.com>2014-07-08 08:12:03 +0000
commit84d0b3efee509e4c820096772981adeb6568978f (patch)
tree7f24a3a2722c4f05eef7c831cca58f09281d18cc /clang/lib/Basic
parentefbce587759f70ad651c98b93e9590751b0e3ce9 (diff)
downloadbcm5719-llvm-84d0b3efee509e4c820096772981adeb6568978f.tar.gz
bcm5719-llvm-84d0b3efee509e4c820096772981adeb6568978f.zip
[OPENMP] Parsing and sema analysis for 'omp parallel sections' directive.
llvm-svn: 212516
Diffstat (limited to 'clang/lib/Basic')
-rw-r--r--clang/lib/Basic/OpenMPKinds.cpp18
1 files changed, 14 insertions, 4 deletions
diff --git a/clang/lib/Basic/OpenMPKinds.cpp b/clang/lib/Basic/OpenMPKinds.cpp
index 6107de16726..b48c02ca266 100644
--- a/clang/lib/Basic/OpenMPKinds.cpp
+++ b/clang/lib/Basic/OpenMPKinds.cpp
@@ -227,6 +227,16 @@ bool clang::isAllowedClauseForDirective(OpenMPDirectiveKind DKind,
break;
}
break;
+ case OMPD_parallel_sections:
+ switch (CKind) {
+#define OPENMP_PARALLEL_SECTIONS_CLAUSE(Name) \
+ case OMPC_##Name: \
+ return true;
+#include "clang/Basic/OpenMPKinds.def"
+ default:
+ break;
+ }
+ break;
case OMPD_unknown:
case OMPD_threadprivate:
case OMPD_task:
@@ -243,13 +253,13 @@ bool clang::isOpenMPLoopDirective(OpenMPDirectiveKind DKind) {
bool clang::isOpenMPWorksharingDirective(OpenMPDirectiveKind DKind) {
return DKind == OMPD_for || DKind == OMPD_sections || DKind == OMPD_section ||
- DKind == OMPD_single ||
- DKind == OMPD_parallel_for; // TODO add next directives.
+ DKind == OMPD_single || DKind == OMPD_parallel_for ||
+ DKind == OMPD_parallel_sections; // TODO add next directives.
}
bool clang::isOpenMPParallelDirective(OpenMPDirectiveKind DKind) {
- return DKind == OMPD_parallel ||
- DKind == OMPD_parallel_for; // TODO add next directives.
+ return DKind == OMPD_parallel || DKind == OMPD_parallel_for ||
+ DKind == OMPD_parallel_sections; // TODO add next directives.
}
bool clang::isOpenMPSimdDirective(OpenMPDirectiveKind DKind) {
OpenPOWER on IntegriCloud