diff options
author | Kelvin Li <kkwli0@gmail.com> | 2016-12-16 20:50:46 +0000 |
---|---|---|
committer | Kelvin Li <kkwli0@gmail.com> | 2016-12-16 20:50:46 +0000 |
commit | 193ee2db477f8928b4d311bac2266a8270d0f728 (patch) | |
tree | ec8ec1f72a78b16f88e6ef0a91316e769f67daa3 /clang/lib/Sema/SemaOpenMP.cpp | |
parent | 90b6b5074af4a9626bdd79d11193bdbcb7e58d94 (diff) | |
download | bcm5719-llvm-193ee2db477f8928b4d311bac2266a8270d0f728.tar.gz bcm5719-llvm-193ee2db477f8928b4d311bac2266a8270d0f728.zip |
[OpenMP] support the 'is_device_ptr' clause with 'target parallel' pragma
This patch is to add support of the 'is_device_ptr' clause in the 'target parallel' pragma.
Differential Revision: https://reviews.llvm.org/D27821
llvm-svn: 289989
Diffstat (limited to 'clang/lib/Sema/SemaOpenMP.cpp')
-rw-r--r-- | clang/lib/Sema/SemaOpenMP.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/clang/lib/Sema/SemaOpenMP.cpp b/clang/lib/Sema/SemaOpenMP.cpp index 3098d07f50e..9b75001ea98 100644 --- a/clang/lib/Sema/SemaOpenMP.cpp +++ b/clang/lib/Sema/SemaOpenMP.cpp @@ -7265,7 +7265,8 @@ OMPClause *Sema::ActOnOpenMPPrivateClause(ArrayRef<Expr *> VarList, // OpenMP 4.5 [2.15.5.1, Restrictions, p.3] // A list item cannot appear in both a map clause and a data-sharing // attribute clause on the same construct - if (DSAStack->getCurrentDirective() == OMPD_target) { + if (DSAStack->getCurrentDirective() == OMPD_target || + DSAStack->getCurrentDirective() == OMPD_target_parallel) { OpenMPClauseKind ConflictKind; if (DSAStack->checkMappableExprComponentListsForDecl( VD, /*CurrentRegionOnly=*/true, @@ -7522,7 +7523,7 @@ OMPClause *Sema::ActOnOpenMPFirstprivateClause(ArrayRef<Expr *> VarList, // OpenMP 4.5 [2.15.5.1, Restrictions, p.3] // A list item cannot appear in both a map clause and a data-sharing // attribute clause on the same construct - if (CurrDir == OMPD_target) { + if (CurrDir == OMPD_target || CurrDir == OMPD_target_parallel) { OpenMPClauseKind ConflictKind; if (DSAStack->checkMappableExprComponentListsForDecl( VD, /*CurrentRegionOnly=*/true, |