From 251e1488e195a0ab618e503fe5b2bc8ff18d1724 Mon Sep 17 00:00:00 2001 From: Michael Kruse Date: Fri, 1 Feb 2019 20:25:04 +0000 Subject: [OpenMP 5.0] Parsing/sema support for "omp declare mapper" directive. This patch implements parsing and sema for "omp declare mapper" directive. User defined mapper, i.e., declare mapper directive, is a new feature in OpenMP 5.0. It is introduced to extend existing map clauses for the purpose of simplifying the copy of complex data structures between host and device (i.e., deep copy). An example is shown below: struct S { int len; int *d; }; #pragma omp declare mapper(struct S s) map(s, s.d[0:s.len]) // Memory region that d points to is also mapped using this mapper. Contributed-by: Lingda Li Differential Revision: https://reviews.llvm.org/D56326 llvm-svn: 352906 --- clang/lib/AST/ItaniumMangle.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'clang/lib/AST/ItaniumMangle.cpp') diff --git a/clang/lib/AST/ItaniumMangle.cpp b/clang/lib/AST/ItaniumMangle.cpp index 34a6181bd4f..5d5d857c44f 100644 --- a/clang/lib/AST/ItaniumMangle.cpp +++ b/clang/lib/AST/ItaniumMangle.cpp @@ -60,7 +60,8 @@ static const DeclContext *getEffectiveDeclContext(const Decl *D) { } const DeclContext *DC = D->getDeclContext(); - if (isa(DC) || isa(DC)) { + if (isa(DC) || isa(DC) || + isa(DC)) { return getEffectiveDeclContext(cast(DC)); } -- cgit v1.2.3