Use a temp pass through errhandler for trivial errors causing abort #2231
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
TYPE: bug fix
KEYWORDS: mpi, quilting, comm
SOURCE: internal
DESCRIPTION OF CHANGES:
Problem:
PR #2157 added changes to match an appropriate
MPI_Datatype
to a specifictypesize
duringcol_on_comm()
anddst_on_comm()
. This relies onMPI_Type_match_size()
to query MPI about the equivalent MPI definition for a particular datatype size. There are safety checks to queryMPI_TYPECLASS_INTEGER
ifMPI_TYPECLASS_REAL
fails.However, when given a datatype size that does not match a possible
MPI_TYPECLASS_REAL
value (e.g. 1 byte where no real exists for single byte) instead of getting a failure via return code the query is treated as a critical failure and fully aborts the program. As the query does not rely on critical process handling and since there already exists adequate checks to abort if no sufficient value is found, this preemptive abort is unnecessary.Solution:
Temporarily install a pass through errhandler that does not modify the return code but also does not abort. Allow the if statements of finding a correct
MPI_Datatype
to abort if deemed necessary. Additionally, once the checks are complete, reinstate any previous errhandler and free our pass through handle.ISSUE:
#2225
TESTS CONDUCTED:
RELEASE NOTE:
In collect_on_comm.c, use a temporary pass through errhandler to allow MPI_Type_match_size to fail correctly with error code rather than fully abort the program.