Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NastyMPI corrupts user-defined MPI data types #3

Open
devreal opened this issue Nov 20, 2017 · 0 comments
Open

NastyMPI corrupts user-defined MPI data types #3

devreal opened this issue Nov 20, 2017 · 0 comments
Assignees
Labels

Comments

@devreal
Copy link
Member

devreal commented Nov 20, 2017

The delayed execution of put/get operations in combination with user-defined MPI data types leads to errors in otherwise correct programs. Consider the following example:

MPI_Win_create(&win);
MPI_Type_vector(..., &new_type);
MPI_Type_commit(&new_type);
MPI_Put(..., new_type, ...);
MPI_Type_destroy(&new_type); // perfectly legal
MPI_Win_flush(win); // <- the above put is deferred until here and executed with a type that has been destroyed

Reference: MPI standard 3.1, §4.1: MPI_Type_free

Marks the datatype object associated with datatype for deallocation and sets datatype
to MPI_DATATYPE_NULL . Any communication that is currently using this datatype will
complete normally.

As a consequence, NastyMPI has to keep track of type usage and destruction and (if necessary) defer type destruction until operations using that type have been started by NastyMPI.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants