Skip to content

MPI_STATUS_SIZE, MPI_SOURCE, MPI_TAG, MPI_ERROR not defined in C #306

Closed
@jsquyres

Description

@jsquyres

Problem

The constants MPI_STATUS_SIZE, MPI_SOURCE, MPI_TAG, and MPI_ERROR are specifically not defined in C.

Proposal

Add MPI_F_STATUS_SIZE, MPI_F_SOURCE, MPI_F_TAG, and MPI_F_ERROR constants in C. The F in the names emphasizes that these are equivalent values to the already-defined-in-Fortran constants.

Note that the _SOURCE, _TAG, and _ERROR constants are 1 less than their Fortran counterparts (since they are offsets into an array, and Fortran and C differ in their handling of array offsets).

Changes to the Text

  1. Add MPI_F_STATUS_SIZE up in chapter 2/terms and conditions
  2. Add the other MPI_F_ constants in chapter 18/language bindings

Corresponding PRs:

Impact on Implementations

Add MPI_F_STATUS_SIZE, MPI_F_SOURCE, MPI_F_TAG, and MPI_F_ERROR constants in mpi.h.

Impact on Users

Users can allocate INTEGER-style Fortran statuses in C and properly read their values.

References

https://lists.mpi-forum.org/pipermail/mpiwg-fortran/2020-September/003584.html

Metadata

Metadata

Assignees

No one assigned

    Labels

    chap-bindingsLanguage Bindings Chapter CommitteeerrataErrata items for the previous MPI Standardpassed final votePassed the final formal votescheduled readingReading is scheduled for the next meetingwg-fortranFortran Working Group

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions