mpich icon indicating copy to clipboard operation
mpich copied to clipboard

RFC: bindings_f08: Use normal MPI C binding to allow profiling by C code

Open N00byKing opened this issue 8 months ago • 1 comments

Pull Request Description

This PR changes some of the generated bindings for the mpi_f08 module to use the standard C MPI functions internally, allowing profiling tools to intercept them. This matches the behavior of the Fortran 90 module, and the rest of the Fortran 2008 bindings, which already allowed for this (Fortran Interface -> Fortran _f08 Impl -> MPIR_ cdesc -> MPI C call).

I rely on this behavior to allow PnMPI and MUST [1] to run on Fortran 2008 code. Without these changes, some interceptions work, while others do not.

I understand this may not be a supported workflow, but I find it useful nonetheless. Pull Request is an RFC, feel free to reject if this change is unwanted.

[1] https://www.i12.rwth-aachen.de/cms/i12/forschung/forschungsschwerpunkte/lehrstuhl-fuer-hochleistungsrechnen/~nrbe/must/

Author Checklist

  • [x] Provide Description Particularly focus on why, not what. Reference background, issues, test failures, xfail entries, etc.
  • [x] Commits Follow Good Practice Commits are self-contained and do not do two things at once. Commit message is of the form: module: short description Commit message explains what's in the commit.
  • [x] Passes All Tests Whitespace checker. Warnings test. Additional tests via comments.
  • [x] Contribution Agreement For non-Argonne authors, check contribution agreement. If necessary, request an explicit comment from your companies PR approval manager.

N00byKing avatar Jun 25 '25 11:06 N00byKing

I think it is okay

hzhou avatar Jun 25 '25 21:06 hzhou