OPALX (Object Oriented Parallel Accelerator Library for Exascale)
MINIorX
OPALX
Request.cpp
Go to the documentation of this file.
1
//
2
// Class Request
3
// A communication request handle for non-blocking communication.
4
//
5
#include "
Communicate/Request.h
"
6
7
namespace
ippl
{
8
namespace
mpi {
9
10
Request::~Request
() {
11
if
(
request_m
!= MPI_REQUEST_NULL) {
12
this->
free
();
13
}
14
}
15
16
bool
Request::completed
() {
17
int
flag = 0;
18
19
Status
status;
20
21
// MPI_STATUS_IGNORE
22
MPI_Request_get_status(
request_m
, &flag, status);
23
24
if
(flag != 0) {
25
// valid Status instance
26
MPI_Test(&
request_m
, &flag, status);
27
}
else
{
28
// Although we free the request, any ongoing communication
29
// associated with this request is allowed to complete.
30
this->
free
();
31
}
32
33
return
(flag != 0);
34
}
35
}
// namespace mpi
36
}
// namespace ippl
Request.h
ippl
Implementations for FFT constructor/destructor and transforms.
Definition:
Archive.h:20
ippl::mpi::Request::~Request
~Request()
Definition:
Request.cpp:10
ippl::mpi::Request::free
void free()
Definition:
Request.h:30
ippl::mpi::Request::request_m
MPI_Request request_m
Definition:
Request.h:35
ippl::mpi::Request::completed
bool completed()
Definition:
Request.cpp:16
ippl::mpi::Status
Definition:
Status.h:14
ippl
src
Communicate
Request.cpp
Generated on Fri Jan 23 2026 14:39:59 for OPALX (Object Oriented Parallel Accelerator Library for Exascale) by
1.9.3