Skip to content

Commit 36f0b6e

Browse files
adiosRerouting: Non-blocking send returns the request
1 parent 47d9e12 commit 36f0b6e

2 files changed

Lines changed: 5 additions & 3 deletions

File tree

source/adios2/helper/adiosRerouting.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,8 @@ namespace adios2
2323
namespace helper
2424
{
2525

26-
void RerouteMessage::NonBlockingSendTo(helper::Comm &comm, int destRank, std::vector<char> &buffer)
26+
helper::Comm::Req RerouteMessage::NonBlockingSendTo(helper::Comm &comm, int destRank,
27+
std::vector<char> &buffer)
2728
{
2829
size_t pos = 0;
2930
buffer.resize(REROUTE_MESSAGE_SIZE);
@@ -45,7 +46,7 @@ void RerouteMessage::NonBlockingSendTo(helper::Comm &comm, int destRank, std::ve
4546

4647
// std::cout << ss.str();
4748

48-
comm.Isend(buffer.data(), buffer.size(), destRank, 0);
49+
return comm.Isend(buffer.data(), buffer.size(), destRank, 0);
4950
}
5051

5152
void RerouteMessage::BlockingSendTo(helper::Comm &comm, int destRank, std::vector<char> &buffer)

source/adios2/helper/adiosRerouting.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,8 @@ class RerouteMessage
6363
}
6464

6565
// Send the contents of this message to another rank
66-
void NonBlockingSendTo(helper::Comm &comm, int destRank, std::vector<char> &buffer);
66+
helper::Comm::Req NonBlockingSendTo(helper::Comm &comm, int destRank,
67+
std::vector<char> &buffer);
6768
void BlockingSendTo(helper::Comm &comm, int destRank, std::vector<char> &buffer);
6869

6970
// Receive a message from another rank to populate this message

0 commit comments

Comments
 (0)