[MOAB-dev] possible bug in WriteHDF5Parallel.cpp
Mark Filipiak
mjf at staffmail.ed.ac.uk
Mon Jun 30 08:27:15 CDT 2014
Hi,
I think there is a bug in WriteHDF5Parallel.cpp (MOAB 4.6.3 and 4.6.2),
where an arbitrary MPI message tag is used:
ErrorCode WriteHDF5Parallel::communicate_shared_set_ids( const Range& owned,
const Range& remote
)
{
ErrorCode rval;
int mperr;
const int TAG = 0xDEADF00;
...
mperr = MPI_Irecv( &recv_buf[i][0], recv_buf[i].size(),
MPI_UNSIGNED_LONG,
procs[i], TAG, comm, &recv_req[i] );
CHECK_MPI(mperr);
...
mperr = MPI_Isend( &send_buf[i][0], send_buf[i].size(),
MPI_UNSIGNED_LONG,
si->first, TAG, comm, &send_req[i] );
...
The value 0xDEADF00 gives me an MPI tag error when running the
parallel_hdf5_test after building MOAB on a Cray XC30 with the Gnu compiler.
The code should use an MPI enquiry function to get the maximum allowed value
for a tag (MPI_TAG_UB) and choose an arbitrary value less than this. The
maximum allowed value is guaranteed to be >= 32767, so you could choose an
arbitrary value >= 0 and <= 32767.
Regards,
Mark
Mark Filipiak
EPCC
The University of Edinburgh
James Clerk Maxwell Building
Mayfield Road
Edinburgh
EH9 3JZ
UK
Telephone +44 131 651 3467
Fax +44 131 650 6555
--
The University of Edinburgh is a charitable body, registered in
Scotland, with registration number SC005336.
More information about the moab-dev
mailing list