[Mlir-commits] [mlir] [MLIR][OpenMP] Add OMP Declare Mapper MLIR Op definition (PR #117045)
Sergio Afonso
llvmlistbot at llvm.org
Fri Feb 7 05:04:31 PST 2025
================
@@ -1689,6 +1689,49 @@ def CancellationPointOp : OpenMP_Op<"cancellation_point", clauses = [
let hasVerifier = 1;
}
+//===----------------------------------------------------------------------===//
+// 2.19.7.3 Declare Mapper Directive
+//===----------------------------------------------------------------------===//
+def DeclareMapperOp : OpenMP_Op<"declare_mapper", [
+ AffineScope,
+ AutomaticAllocationScope,
+ IsolatedFromAbove,
+ OutlineableOpenMPOpInterface,
+ RecipeInterface,
+ Symbol
+ ]> {
+ let summary = "declare mapper directive";
+ let description = [{
+ The declare mapper directive declares a user-defined mapper for a given
+ type, and defines a mapper-identifier that can be used in a map clause.
+ }] # clausesDescription;
+
+ let arguments = (ins SymbolNameAttr:$sym_name,
+ TypeAttr:$var_type);
----------------
skatrak wrote:
Nit: For consistency with the similar `omp.private` and `omp.declare_reduction` ops, it should be named just `$type`.
https://github.com/llvm/llvm-project/pull/117045
More information about the Mlir-commits
mailing list