ABataev added inline comments. ================ Comment at: include/clang/AST/OpenMPClause.h:2660-2662 @@ +2659,5 @@ + /// + /// \param StartLoc Starting location of the clause. + /// \param EndLoc Ending location of the clause. + /// \param N Number of the variables in the clause. + /// ---------------- Not all important arguments are described
================ Comment at: include/clang/AST/OpenMPClause.h:2683-2686 @@ +2682,6 @@ + /// + /// \param C AST context. + /// \brief StartLoc Starting location of the clause. + /// \brief EndLoc Ending location of the clause. + /// \param VL List of references to the variables. + /// ---------------- Not all important arguments are described ================ Comment at: lib/Basic/OpenMPKinds.cpp:199 @@ +198,3 @@ + return "unknown"; +#define OPENMP_MAP_KIND(Name ) \ + case OMPC_MAP_##Name: \ ---------------- Extra spaces between arg and ')' ================ Comment at: lib/Sema/SemaOpenMP.cpp:318-342 @@ -310,1 +317,27 @@ + + MapInfo getMapInfoForVar(VarDecl *VD) { + MapInfo Tmp = {0}; + for (auto Cnt = Stack.size() - 1; Cnt > 0; --Cnt) { + if (Stack[Cnt].MappedDecls.count(VD)) { + Tmp = Stack[Cnt].MappedDecls[VD]; + break; + } + } + return Tmp; + } + + void addMapInfoForVar(VarDecl *VD, MapInfo MI) { + if (Stack.size() > 1) { + Stack.back().MappedDecls[VD] = MI; + } + } + + MapInfo IsMappedInCurrentRegion(VarDecl *VD) { + assert(Stack.size() > 1 && "Target level is 0"); + MapInfo Tmp = {0}; + if (Stack.size() > 1 && Stack.back().MappedDecls.count(VD)) { + Tmp = Stack.back().MappedDecls[VD]; + } + return Tmp; + } }; ---------------- Tmp is bad name. ================ Comment at: test/OpenMP/target_data_ast_print.cpp:1 @@ -1,2 +1,2 @@ // RUN: %clang_cc1 -verify -fopenmp -ast-print %s | FileCheck %s // RUN: %clang_cc1 -fopenmp -x c++ -std=c++11 -emit-pch -o %t %s ---------------- Also add tests for templates, serialization/deserialization ================ Comment at: test/OpenMP/target_map_messages.cpp:2 @@ +1,3 @@ +// RUN: %clang_cc1 -verify -fopenmp -ferror-limit 100 %s + +void foo() { ---------------- Still no tests for templates http://reviews.llvm.org/D14134 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits