summaryrefslogtreecommitdiffstats
path: root/clang/lib/Basic
diff options
context:
space:
mode:
authorAlexey Bataev <a.bataev@hotmail.com>2014-06-26 12:05:45 +0000
committerAlexey Bataev <a.bataev@hotmail.com>2014-06-26 12:05:45 +0000
commitd1e40fbfe1c38f5778c739d1fc1b3bcf156ccb58 (patch)
tree30b273a3b64072c964ed33986d2de6362af8c7d8 /clang/lib/Basic
parentaee45418287cdcc1387c56e0c0d08990c322b45b (diff)
downloadbcm5719-llvm-d1e40fbfe1c38f5778c739d1fc1b3bcf156ccb58.tar.gz
bcm5719-llvm-d1e40fbfe1c38f5778c739d1fc1b3bcf156ccb58.zip
[OPENMP] Initial parsing and sema analysis for 'single' directive.
llvm-svn: 211774
Diffstat (limited to 'clang/lib/Basic')
-rw-r--r--clang/lib/Basic/OpenMPKinds.cpp14
1 files changed, 12 insertions, 2 deletions
diff --git a/clang/lib/Basic/OpenMPKinds.cpp b/clang/lib/Basic/OpenMPKinds.cpp
index 547eb32199b..623af2df60a 100644
--- a/clang/lib/Basic/OpenMPKinds.cpp
+++ b/clang/lib/Basic/OpenMPKinds.cpp
@@ -201,6 +201,16 @@ bool clang::isAllowedClauseForDirective(OpenMPDirectiveKind DKind,
break;
}
break;
+ case OMPD_single:
+ switch (CKind) {
+#define OPENMP_SINGLE_CLAUSE(Name) \
+ case OMPC_##Name: \
+ return true;
+#include "clang/Basic/OpenMPKinds.def"
+ default:
+ break;
+ }
+ break;
case OMPD_unknown:
case OMPD_threadprivate:
case OMPD_task:
@@ -215,8 +225,8 @@ bool clang::isOpenMPLoopDirective(OpenMPDirectiveKind DKind) {
}
bool clang::isOpenMPWorksharingDirective(OpenMPDirectiveKind DKind) {
- return DKind == OMPD_for || DKind == OMPD_sections ||
- DKind == OMPD_section; // TODO add next directives.
+ return DKind == OMPD_for || DKind == OMPD_sections || DKind == OMPD_section ||
+ DKind == OMPD_single; // TODO add next directives.
}
bool clang::isOpenMPParallelDirective(OpenMPDirectiveKind DKind) {
OpenPOWER on IntegriCloud