diff options
author | Samuel Antao <sfantao@us.ibm.com> | 2016-07-28 14:25:09 +0000 |
---|---|---|
committer | Samuel Antao <sfantao@us.ibm.com> | 2016-07-28 14:25:09 +0000 |
commit | f15ab0cbaee2580b3ee1ff3d09851aa89d5b131f (patch) | |
tree | 7f5377569a7f18ab77b84a8a61442d178dd78594 /lib/Serialization/ASTWriterStmt.cpp | |
parent | 56b9ac6ad63c9f348accee7e00130b872564efa3 (diff) |
[OpenMP] Code generation for the is_device_ptr clause
Summary: This patch adds support for the is_device_ptr clause. It expands SEMA to use the mappable expression logic that can only be tested with code generation in place and check conflicts with other data sharing related clauses using the mappable expressions infrastructure.
Reviewers: hfinkel, carlo.bertolli, arpith-jacob, kkwli0, ABataev
Subscribers: caomhin, cfe-commits
Differential Revision: https://reviews.llvm.org/D22788
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@276978 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Serialization/ASTWriterStmt.cpp')
-rw-r--r-- | lib/Serialization/ASTWriterStmt.cpp | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/lib/Serialization/ASTWriterStmt.cpp b/lib/Serialization/ASTWriterStmt.cpp index 611ace958f..9cc867a518 100644 --- a/lib/Serialization/ASTWriterStmt.cpp +++ b/lib/Serialization/ASTWriterStmt.cpp @@ -2175,9 +2175,21 @@ void OMPClauseWriter::VisitOMPUseDevicePtrClause(OMPUseDevicePtrClause *C) { void OMPClauseWriter::VisitOMPIsDevicePtrClause(OMPIsDevicePtrClause *C) { Record.push_back(C->varlist_size()); + Record.push_back(C->getUniqueDeclarationsNum()); + Record.push_back(C->getTotalComponentListNum()); + Record.push_back(C->getTotalComponentsNum()); Record.AddSourceLocation(C->getLParenLoc()); - for (auto *VE : C->varlists()) { - Record.AddStmt(VE); + for (auto *E : C->varlists()) + Record.AddStmt(E); + for (auto *D : C->all_decls()) + Record.AddDeclRef(D); + for (auto N : C->all_num_lists()) + Record.push_back(N); + for (auto N : C->all_lists_sizes()) + Record.push_back(N); + for (auto &M : C->all_components()) { + Record.AddStmt(M.getAssociatedExpression()); + Record.AddDeclRef(M.getAssociatedDeclaration()); } } |