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

Avoiding MPI_Comm_compare altogether in the common case #39

Open
marcgamell opened this issue May 24, 2017 · 1 comment
Open

Avoiding MPI_Comm_compare altogether in the common case #39

marcgamell opened this issue May 24, 2017 · 1 comment

Comments

@marcgamell
Copy link
Contributor

What I suggest is to optimize for the common case. In the common case we don’t need to call MPI_Comm_compare at all. Therefore, we can convert the code in PMPI functions to something like:
If(use_hack) {
If(comm___ == comm) Use resilient_comm;
Else Use comm;
} else {
MPI_Comm_compare(dup_of_input_comm, comm);
If(CONGRUENT) Use resilient_comm;
Else Use comm;
}

We can determine in Fenix_Init if use_hack is appropriate or not. For OpenMPI (and probably MPICH, once ULFM is implemented in it), use_hack will always be true. This would solve the AMR case in which many different comms are used.

@marcgamell
Copy link
Contributor Author

George confirmed that direct comparison should work for all libraries:
For MPI_IDENT a direct comparison with == should work for all libraries.

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

No branches or pull requests

1 participant