Skip to content

Commit 2622d40

Browse files
committed
add documentation
1 parent 188ef3c commit 2622d40

File tree

2 files changed

+12
-3
lines changed

2 files changed

+12
-3
lines changed

mlir/include/mlir/Dialect/MPI/IR/MPIBase.td

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,11 @@ def MPI_Dialect : Dialect {
1515
let name = "mpi";
1616
let cppNamespace = "::mlir::mpi";
1717
let description = [{
18-
TODO
18+
This dialect models the Message Passing Interface (MPI), version 4.0. It is meant
19+
to serve as a targetable dialect, that can be lowered to multiple MPI implementations
20+
and hide differences in ABI between these. The dialect models the functions of the MPI
21+
specification as close to 1:1 as possible while preserving SSA value semantics where it
22+
makes sense, and uses `memref` types instead of bare pointers.
1923

2024
This dialect is under active development, and while stability is an
2125
eventual goal, it is not guaranteed at this juncture. Given the early state,

mlir/include/mlir/Dialect/MPI/IR/MPIOps.td

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,8 @@ def MPI_InitOp : MPI_Op<"init", [
2323
]> {
2424
let summary = "Initialize the MPI library, equivalent to `MPI_Init(NULL, NULL)`";
2525
let description = [{
26-
Passing &argc, &argv is not supported currently, also inspecting the return value is not supported.
26+
Passing &argc, &argv is not supported currently.
27+
Inspecting the return value (error code) is also not supported.
2728
}];
2829

2930
let assemblyFormat = "attr-dict";
@@ -39,6 +40,7 @@ def MPI_CommRankOp : MPI_Op<"comm_rank", [
3940
let summary = "Get the current rank, equivalent to `MPI_Comm_rank(MPI_COMM_WORLD, &rank)`";
4041
let description = [{
4142
Communicators other than `MPI_COMM_WORLD` are not supprted for now.
43+
Inspecting the return value (error code) is also not supported.
4244
}];
4345

4446
let results = (outs
@@ -59,6 +61,7 @@ def MPI_SendOp : MPI_Op<"send", [
5961
let summary = "Equivalent to `MPI_Send(ptr, size, dtype, dest, tag, MPI_COMM_WORLD)`";
6062
let description = [{
6163
Communicators other than `MPI_COMM_WORLD` are not supprted for now.
64+
Inspecting the return value (error code) is also not supported.
6265
}];
6366

6467
let arguments = (ins
@@ -80,6 +83,8 @@ def MPI_RecvOp : MPI_Op<"recv", [
8083
let summary = "Equivalent to `MPI_Recv(ptr, size, dtype, dest, tag, MPI_COMM_WORLD, MPI_STATUS_IGNORE)`";
8184
let description = [{
8285
Communicators other than `MPI_COMM_WORLD` are not supprted for now.
86+
The MPI_Status is set to `MPI_STATUS_IGNORE`, as the status object is not yet ported to MLIR.
87+
Inspecting the return value (error code) is also not supported.
8388
}];
8489

8590
let arguments = (ins
@@ -100,7 +105,7 @@ def MPI_FinalizeOp : MPI_Op<"finalize", [
100105
]> {
101106
let summary = "Finalize the MPI library, equivalent to `MPI_Finalize()`";
102107
let description = [{
103-
108+
Inspecting the return value (error code) is not supported.
104109
}];
105110

106111
let assemblyFormat = "attr-dict";

0 commit comments

Comments
 (0)