Skip to content

sessions: make sure to only finalize class #12888

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

Merged
merged 1 commit into from
Oct 29, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 1 addition & 5 deletions examples/hello_sessions_c.c
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,10 @@ int main(int argc, char** argv) {
MPI_Info info;
MPI_Session s1, s2;

#if 0
/* need PR https://github.com/open-mpi/ompi/pull/12868 to be merged in
* before this can be uncommented.
*/
MPI_Info_create(&info);
#endif
MPI_Session_init(MPI_INFO_NULL, MPI_ERRORS_RETURN, &s1);
MPI_Session_finalize(&s1);
MPI_Session_init(MPI_INFO_NULL, MPI_ERRORS_RETURN, &s2);
MPI_Session_finalize(&s2);
MPI_Info_free(&info);
}
7 changes: 0 additions & 7 deletions ompi/instance/instance.c
Original file line number Diff line number Diff line change
Expand Up @@ -954,13 +954,6 @@ static int ompi_mpi_instance_finalize_common (void)

ompi_mpi_instance_release ();

if (0 == opal_initialized) {
/* if there is no MPI_T_init_thread that has been MPI_T_finalize'd,
* then be gentle to the app and release all the memory now (instead
* of the opal library destructor */
opal_class_finalize ();
}

return OMPI_SUCCESS;
}

Expand Down
Loading