You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Determine MPI Data Types in col_on_comm() & dst_on_comm() to prevent displacements overflow. (Fix for #2156) (#2157)
Determine MPI Data Types in col_on_comm() & dst_on_comm() to prevent
displacements overflow.
TYPE: bug fix
KEYWORDS: prevent displacements overflow in MPI_Gatherv() and
MPI_Scatterv() operations
SOURCE: Benjamin Kirk & Negin Sobhani (NSF NCAR / CISL)
DESCRIPTION OF CHANGES:
Problem:
The MPI_Gatherv() and MPI_Scatterv() operations require integer
displacements into the communications buffers. Historically everything
is passed as an MPI_CHAR, causing these displacements to be larger than
otherwise necessary. For large domain sizes this can cause the
displace[] offsets to exceed the maximum int, wrapping to negative
values.
Solution:
This change introduces additional error checking and then uses the
function MPI_Type_match_size() (available since MPI-2.0) to determine a
suitable MPI_Datatype given the input *typesize. The result then is that
the displace[] offsets are in terms of data type extents, rather than
bytes, and less likely to overflow.
ISSUE: Fixes#2156
LIST OF MODIFIED FILES:
M frame/collect_on_comm.c
TESTS CONDUCTED:
Failed cases run now.
RELEASE NOTE:
Determine MPI Data Types in col_on_comm() & dst_on_comm() to prevent
displacements overflow.
0 commit comments