mirror of
https://github.com/OPM/opm-simulators.git
synced 2024-11-26 03:00:17 -06:00
Avoid assert and rely on error handler doing the correct thing.
Checking int return types of MPI functions is inefficient. The default error handler will abort the problem. If somebody changes that, then they should know what they are doing.
This commit is contained in:
parent
6d70d090a8
commit
1e8b51f118
@ -111,19 +111,13 @@ public:
|
||||
void receive([[maybe_unused]] unsigned peerRank)
|
||||
{
|
||||
#if HAVE_MPI
|
||||
// Use return code for error detection
|
||||
// According to MPI standard the ERROR field
|
||||
// might not be initialized unless for operations
|
||||
// that return multiple statuses, see Section 3.7.5
|
||||
// of the standard
|
||||
[[maybe_unused]] auto result = MPI_Recv(data_,
|
||||
MPI_Recv(data_,
|
||||
static_cast<int>(mpiDataSize_),
|
||||
mpiDataType_,
|
||||
static_cast<int>(peerRank),
|
||||
0, // tag
|
||||
MPI_COMM_WORLD,
|
||||
MPI_STATUS_IGNORE);
|
||||
assert(!result);
|
||||
#endif // HAVE_MPI
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user