PPL Logo

AmpiRequest Class Reference

Represents an MPI request that has been initiated using Isend, Irecv, Ialltoall, Send_init, etc. More...

#include <ampiimpl.h>

Inheritance diagram for AmpiRequest:

Inheritance graph
[legend]
Collaboration diagram for AmpiRequest:

Collaboration graph
[legend]

Public Member Functions

 AmpiRequest ()
virtual ~AmpiRequest ()
virtual void start (MPI_Request reqIdx) noexcept
 Activate this persistent request.
virtual int getTag () const noexcept
 Used by AmmEntry's constructor.
virtual int getSrcRank () const noexcept
virtual bool test (MPI_Status *sts=MPI_STATUS_IGNORE) noexcept=0
 Return true if this request is finished (progress):.
virtual int wait (MPI_Status *sts) noexcept=0
 Block until this request is finished, returning a valid MPI error code.
virtual void cancel () noexcept
 Mark this request for cancellation.
virtual void setPersistent (bool p) noexcept
 Mark this request persistent.
virtual bool isPersistent () const noexcept
virtual void receive (ampi *ptr, AmpiMsg *msg, bool deleteMsg=true) noexcept=0
 Receive an AmpiMsg.
virtual void receive (ampi *ptr, CkReductionMsg *msg) noexcept=0
 Receive a CkReductionMsg.
virtual void receiveRdma (ampi *ptr, char *sbuf, int slength, int ssendReq, int srcRank, MPI_Comm scomm) noexcept
 Receive an Rdma message.
void setReqIdx (MPI_Request idx) noexcept
 Set the request's index into AmpiRequestList.
MPI_Request getReqIdx () const noexcept
void free (CkDDT *ddt) noexcept
 Free the request's datatype.
void setBlocked (bool b) noexcept
 Set whether the request is currently blocked on.
bool isBlocked () const noexcept
virtual AmpiReqType getType () const noexcept=0
 Returns the type of request: AMPI_I_REQ, AMPI_ATA_REQ, AMPI_SEND_REQ, AMPI_SSEND_REQ, AMPI_REDN_REQ, AMPI_GATHER_REQ, AMPI_GATHERV_REQ, AMPI_G_REQ.
virtual bool isUnmatched () const noexcept=0
 Returns whether this request will need to be matched.
virtual bool isPooledType () const noexcept
 Returns whether this type is pooled or not: Only AMPI_I_REQ, AMPI_SEND_REQ, and AMPI_SSEND_REQs are pooled.
virtual int getNumReceivedBytes (CkDDT *ddt) const noexcept
 Return the actual number of bytes that were received.
virtual void pup (PUP::er &p) noexcept
virtual void print () const noexcept=0

Data Fields

void * buf = nullptr
int count = 0
MPI_Datatype type = MPI_DATATYPE_NULL
int tag = MPI_ANY_TAG
int src = MPI_ANY_SOURCE
MPI_Comm comm = MPI_COMM_NULL
MPI_Request reqIdx = MPI_REQUEST_NULL
bool complete = false
bool blocked = false
void * event = nullptr
int eventPe = -1

Detailed Description

Represents an MPI request that has been initiated using Isend, Irecv, Ialltoall, Send_init, etc.

Definition at line 1097 of file ampiimpl.h.


Constructor & Destructor Documentation

AmpiRequest::AmpiRequest (  ) 

virtual AmpiRequest::~AmpiRequest (  )  [virtual]


Member Function Documentation

virtual void AmpiRequest::start ( MPI_Request  reqIdx  )  [inline, virtual]

Activate this persistent request.

Only meaningful for persistent Ireq, SendReq, and SsendReq requests.

Reimplemented in final, final, and final.

Definition at line 1121 of file ampiimpl.h.

virtual int AmpiRequest::getTag (  )  const [inline, virtual]

Used by AmmEntry's constructor.

Reimplemented in final.

Definition at line 1124 of file ampiimpl.h.

References tag.

virtual int AmpiRequest::getSrcRank (  )  const [inline, virtual]

Reimplemented in final.

Definition at line 1125 of file ampiimpl.h.

References src.

virtual bool AmpiRequest::test ( MPI_Status sts = MPI_STATUS_IGNORE  )  [pure virtual]

Return true if this request is finished (progress):.

Implemented in final, final, final, final, final, final, GPUReq, final, and final.

Referenced by AMPI_API_IMPL(), testRequest(), and testRequestNoFree().

Here is the caller graph for this function:

virtual int AmpiRequest::wait ( MPI_Status sts  )  [pure virtual]

Block until this request is finished, returning a valid MPI error code.

Implemented in final, final, final, final, final, final, GPUReq, final, and final.

Referenced by AMPI_API_IMPL(), testRequest(), and testRequestNoFree().

Here is the caller graph for this function:

virtual void AmpiRequest::cancel (  )  [inline, virtual]

Mark this request for cancellation.

Supported only for IReq requests

Reimplemented in final, final, final, and final.

Definition at line 1136 of file ampiimpl.h.

Referenced by AMPI_API_IMPL().

Here is the caller graph for this function:

virtual void AmpiRequest::setPersistent ( bool  p  )  [inline, virtual]

Mark this request persistent.

Supported only for IReq, SendReq, and SsendReq requests

Reimplemented in final, final, and final.

Definition at line 1140 of file ampiimpl.h.

virtual bool AmpiRequest::isPersistent (  )  const [inline, virtual]

Reimplemented in final, final, and final.

Definition at line 1141 of file ampiimpl.h.

virtual void AmpiRequest::receive ( ampi *  ptr,
AmpiMsg *  msg,
bool  deleteMsg = true 
) [pure virtual]

Receive an AmpiMsg.

Implemented in final, final, final, final, final, final, GPUReq, final, and final.

virtual void AmpiRequest::receive ( ampi *  ptr,
CkReductionMsg msg 
) [pure virtual]

Receive a CkReductionMsg.

Implemented in final, final, final, final, final, final, GPUReq, final, and final.

virtual void AmpiRequest::receiveRdma ( ampi *  ptr,
char *  sbuf,
int  slength,
int  ssendReq,
int  srcRank,
MPI_Comm  scomm 
) [inline, virtual]

Receive an Rdma message.

Reimplemented in final.

Definition at line 1150 of file ampiimpl.h.

void AmpiRequest::setReqIdx ( MPI_Request  idx  )  [inline]

Set the request's index into AmpiRequestList.

Definition at line 1154 of file ampiimpl.h.

References idx.

MPI_Request AmpiRequest::getReqIdx (  )  const [inline]

Definition at line 1155 of file ampiimpl.h.

void AmpiRequest::free ( CkDDT ddt  )  [inline]

Free the request's datatype.

Definition at line 1158 of file ampiimpl.h.

References type.

void AmpiRequest::setBlocked ( bool  b  )  [inline]

Set whether the request is currently blocked on.

Definition at line 1163 of file ampiimpl.h.

References PUP::b.

Referenced by AMPI_API_IMPL().

Here is the caller graph for this function:

bool AmpiRequest::isBlocked (  )  const [inline]

Definition at line 1164 of file ampiimpl.h.

virtual AmpiReqType AmpiRequest::getType (  )  const [pure virtual]

Returns the type of request: AMPI_I_REQ, AMPI_ATA_REQ, AMPI_SEND_REQ, AMPI_SSEND_REQ, AMPI_REDN_REQ, AMPI_GATHER_REQ, AMPI_GATHERV_REQ, AMPI_G_REQ.

Implemented in final, final, final, final, final, final, final, final, final, GPUReq, final, and final.

Referenced by AMPI_API_IMPL().

Here is the caller graph for this function:

virtual bool AmpiRequest::isUnmatched (  )  const [pure virtual]

Returns whether this request will need to be matched.

It is used to determine whether this request should be inserted into postedReqs. AMPI_SEND_REQ, AMPI_SSEND_REQ, and AMPI_ATA_REQ should not be posted.

Implemented in final, final, final, final, final, final, GPUReq, final, and final.

virtual bool AmpiRequest::isPooledType (  )  const [inline, virtual]

Returns whether this type is pooled or not: Only AMPI_I_REQ, AMPI_SEND_REQ, and AMPI_SSEND_REQs are pooled.

Reimplemented in final, final, and final.

Definition at line 1178 of file ampiimpl.h.

virtual int AmpiRequest::getNumReceivedBytes ( CkDDT ddt  )  const [inline, virtual]

Return the actual number of bytes that were received.

Reimplemented in final.

Definition at line 1181 of file ampiimpl.h.

References count, and type.

virtual void AmpiRequest::pup ( PUP::er p  )  [inline, virtual]

Reimplemented in final, final, final, final, final, final, final, final, final, final, final, final, and final.

Definition at line 1186 of file ampiimpl.h.

References buf, comm, complete, count, p, src, tag, and type.

Referenced by final::pup().

Here is the caller graph for this function:

void AmpiRequest::print (  )  const [pure virtual]

Implemented in final, final, final, final, final, final, GPUReq, final, and final.

Definition at line 3754 of file ampi.C.

References blocked, complete, src, and type.

Referenced by GPUReq::print().

Here is the caller graph for this function:


Field Documentation

void* AmpiRequest::buf = nullptr

Definition at line 1099 of file ampiimpl.h.

Referenced by AMPI_API_IMPL(), and AMPI_GPU_complete().

Definition at line 1100 of file ampiimpl.h.

Referenced by AMPI_API_IMPL().

MPI_Datatype AmpiRequest::type = MPI_DATATYPE_NULL

Definition at line 1101 of file ampiimpl.h.

Referenced by AMPI_API_IMPL(), and print().

int AmpiRequest::tag = MPI_ANY_TAG

Reimplemented in final.

Definition at line 1102 of file ampiimpl.h.

int AmpiRequest::src = MPI_ANY_SOURCE

Definition at line 1103 of file ampiimpl.h.

Referenced by AMPI_API_IMPL(), and print().

MPI_Comm AmpiRequest::comm = MPI_COMM_NULL

Reimplemented in final.

Definition at line 1104 of file ampiimpl.h.

MPI_Request AmpiRequest::reqIdx = MPI_REQUEST_NULL

Definition at line 1105 of file ampiimpl.h.

Definition at line 1106 of file ampiimpl.h.

Referenced by print(), GPUReq::setComplete(), GPUReq::test(), and GPUReq::wait().

Definition at line 1107 of file ampiimpl.h.

Referenced by print().

void* AmpiRequest::event = nullptr

Reimplemented in final.

Definition at line 1111 of file ampiimpl.h.

Reimplemented in final.

Definition at line 1112 of file ampiimpl.h.


The documentation for this class was generated from the following files:

Generated on Mon Sep 21 08:17:21 2020 for Charm++ by  doxygen 1.5.5