[Mlir-commits] [mlir] [mlir][mpi] Lowering Mpi To LLVM (PR #127053)
Christian Ulmann
llvmlistbot at llvm.org
Mon Feb 17 23:19:38 PST 2025
================
@@ -0,0 +1,157 @@
+#define MPICH_SKIP_MPICXX 1
+#define OMPI_SKIP_MPICXX 1
+#include "mlir/Dialect/LLVMIR/LLVMDialect.h"
+#include "mlir/Dialect/MPI/IR/MPI.h"
+#include "mlir/Transforms/DialectConversion.h"
+
+// skip if no MPI C header was found
+#ifdef FOUND_MPI_C_HEADER
+#include <mpi.h>
+#else // not FOUND_MPI_C_HEADER
+#include "mpi_fallback.h"
+#endif // FOUND_MPI_C_HEADER
----------------
Dinistro wrote:
Do we have a clear plan of adapting this general format? I understand that this can be annoying to implement, but not doing it now might result in more work down the line.
I know of multiple companies that distribute MLIR in binary form, mine included. For now, we will not rely on the MPI dialect, but this might become an issue at some point. Specifically, setting up the build containers to contain the correct MPI version we want to target will be problematic.
https://github.com/llvm/llvm-project/pull/127053
More information about the Mlir-commits
mailing list