Skip to content

Commit 38ce5eb

Browse files
committed
Address reviewer commits.
1 parent 17d28df commit 38ce5eb

File tree

2 files changed

+8
-9
lines changed

2 files changed

+8
-9
lines changed

mlir/include/mlir/Dialect/OpenMP/OpenMPOps.td

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1753,11 +1753,9 @@ def ScanOp : OpenMP_Op<"scan", [
17531753
// 2.19.7.3 Declare Mapper Directive
17541754
//===----------------------------------------------------------------------===//
17551755
def DeclareMapperOp : OpenMP_Op<"declare_mapper", [
1756-
AffineScope,
1757-
AutomaticAllocationScope,
17581756
IsolatedFromAbove,
1759-
OutlineableOpenMPOpInterface,
17601757
RecipeInterface,
1758+
SingleBlock,
17611759
Symbol
17621760
]> {
17631761
let summary = "declare mapper directive";
@@ -1767,22 +1765,23 @@ def DeclareMapperOp : OpenMP_Op<"declare_mapper", [
17671765
}] # clausesDescription;
17681766

17691767
let arguments = (ins SymbolNameAttr:$sym_name,
1770-
TypeAttr:$var_type);
1768+
TypeAttr:$type);
17711769

17721770
let regions = (region AnyRegion:$body);
17731771

1774-
let assemblyFormat = "$sym_name `:` $var_type $body attr-dict";
1772+
let assemblyFormat = "$sym_name `:` $type $body attr-dict";
17751773
}
17761774

1777-
def DeclareMapperInfoOp : OpenMP_Op<"declare_mapper_info", [
1775+
def DeclareMapperInfoOp : OpenMP_Op<"declare_mapper.info", [
1776+
HasParent<"DeclareMapperOp">,
17781777
Terminator
17791778
], clauses = [
17801779
OpenMP_MapClause
17811780
]> {
17821781
let summary = "declare mapper info";
17831782
let description = [{
17841783
This Op is used to capture the map information related to it's
1785-
parent DeclareMapperOp.]>
1784+
parent DeclareMapperOp.
17861785
}] # clausesDescription;
17871786

17881787
let builders = [

mlir/test/Dialect/OpenMP/ops.mlir

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -884,8 +884,8 @@ omp.declare_mapper @my_mapper : !llvm.struct<"my_type", (i32)> {
884884
^bb0(%arg: !llvm.ptr):
885885
// CHECK: %[[DECL_MAP_INFO:.*]] = omp.map.info var_ptr(%{{.*}} : !llvm.ptr, !llvm.struct<"my_type", (i32)>) map_clauses(tofrom) capture(ByRef) -> !llvm.ptr {name = ""}
886886
%decl_map_info = omp.map.info var_ptr(%arg : !llvm.ptr, !llvm.struct<"my_type", (i32)>) map_clauses(tofrom) capture(ByRef) -> !llvm.ptr {name = ""}
887-
// CHECK: omp.declare_mapper_info map_entries(%[[DECL_MAP_INFO]] : !llvm.ptr)
888-
omp.declare_mapper_info map_entries(%decl_map_info : !llvm.ptr)
887+
// CHECK: omp.declare_mapper.info map_entries(%[[DECL_MAP_INFO]] : !llvm.ptr)
888+
omp.declare_mapper.info map_entries(%decl_map_info : !llvm.ptr)
889889
}
890890

891891
// CHECK-LABEL: func @wsloop_reduction

0 commit comments

Comments
 (0)