PPL Logo

CkCallback Class Reference

#include <ckcallback.h>

Inheritance diagram for CkCallback:

Inheritance graph
[legend]
Collaboration diagram for CkCallback:

Collaboration graph
[legend]

Public Types

enum  callbackType {
  invalid = 0, ignore, ckExit, resumeThread,
  callCFn, call1Fn, sendChare, sendGroup,
  sendNodeGroup, sendArray, isendChare, isendGroup,
  isendNodeGroup, isendArray, bcastGroup, bcastNodeGroup,
  bcastArray, bcastSection, replyCCS
}

Public Member Functions

bool operator== (CkCallback &other)
void impl_thread_init (void)
void * impl_thread_delay (void) const
 CkCallback (void)
 CkCallback (callbackType t)
 CkCallback (Ck1CallbackFn fn)
 CkCallback (CkCallbackFn fn, void *param)
 CkCallback (int ep, const CkChareID &id, bool forceInline=false)
 CkCallback (int ep, const CProxy_NodeGroup &ngp)
 CkCallback (int ep, const CkGroupID &id, bool isNodeGroup=false)
 CkCallback (int ep, int onPE, const CProxy_NodeGroup &ngp, bool forceInline=false)
 CkCallback (int ep, int onPE, const CkGroupID &id, bool forceInline=false, bool isNodeGroup=false)
 CkCallback (int ep, const CProxyElement_Group &grpElt, bool forceInline=false)
 CkCallback (int ep, const CProxyElement_NodeGroup &grpElt, bool forceInline=false)
 CkCallback (int ep, const CkArrayID &id)
 CkCallback (int ep, const CkArrayIndex &idx, const CkArrayID &id, bool forceInline=false)
 CkCallback (int ep, const CProxyElement_ArrayBase &arrElt, bool forceInline=false)
 CkCallback (int ep, CProxySection_ArrayBase &sectElt, bool forceInline=false)
 CkCallback (int ep, CkSectionID &sid)
 CkCallback (Chare *p, int ep, bool forceInline=false)
 CkCallback (Group *p, int ep, bool forceInline=false)
 CkCallback (NodeGroup *p, int ep, bool forceInline=false)
 CkCallback (ArrayElement *p, int ep, bool forceInline=false)
 CkCallback (const CcsDelayedReply &reply)
 ~CkCallback ()
bool isInvalid (void) const
bool requiresMsgConstruction () const
bool containsPointer () const
 Does this callback point at something that may not be at the same address after a checkpoint/restart cycle?
void * thread_delay (void) const
 Interface used by threaded callbacks: Libraries should call these from their "start" entry points.
void thread_destroy () const
void send (void *msg=NULL) const
 Send this message back to the caller.
void send (int length, const void *data) const
 Send this data, formatted as a CkDataMsg, back to the caller.
void pup (PUP::er &p)
void setRefNum (CMK_REFNUM_TYPE refnum)
void setRefnum (CMK_REFNUM_TYPE refnum)

Static Public Member Functions

static const char * typeName (callbackType type)

Data Fields

callbackType type
callbackData d
bool isCkExtReductionCb = false

Data Structures

union  callbackData

Detailed Description

Definition at line 35 of file ckcallback.h.


Member Enumeration Documentation

Enumerator:
invalid 
ignore 
ckExit 
resumeThread 
callCFn 
call1Fn 
sendChare 
sendGroup 
sendNodeGroup 
sendArray 
isendChare 
isendGroup 
isendNodeGroup 
isendArray 
bcastGroup 
bcastNodeGroup 
bcastArray 
bcastSection 
replyCCS 

Definition at line 37 of file ckcallback.h.


Constructor & Destructor Documentation

CkCallback::CkCallback ( void   )  [inline]

Definition at line 220 of file ckcallback.h.

References invalid, and type.

CkCallback::CkCallback ( callbackType  t  )  [inline]

Definition at line 227 of file ckcallback.h.

References impl_thread_init(), resumeThread, and type.

Here is the call graph for this function:

CkCallback::CkCallback ( Ck1CallbackFn  fn  )  [inline]

CkCallback::CkCallback ( CkCallbackFn  fn,
void *  param 
) [inline]

CkCallback::CkCallback ( int  ep,
const CkChareID id,
bool  forceInline = false 
) [inline]

CkCallback::CkCallback ( int  ep,
const CProxy_NodeGroup ngp 
)

CkCallback::CkCallback ( int  ep,
const CkGroupID id,
bool  isNodeGroup = false 
) [inline]

CkCallback::CkCallback ( int  ep,
int  onPE,
const CProxy_NodeGroup ngp,
bool  forceInline = false 
)

CkCallback::CkCallback ( int  ep,
int  onPE,
const CkGroupID id,
bool  forceInline = false,
bool  isNodeGroup = false 
) [inline]

CkCallback::CkCallback ( int  ep,
const CProxyElement_Group &  grpElt,
bool  forceInline = false 
)

CkCallback::CkCallback ( int  ep,
const CProxyElement_NodeGroup grpElt,
bool  forceInline = false 
)

CkCallback::CkCallback ( int  ep,
const CkArrayID id 
) [inline]

CkCallback::CkCallback ( int  ep,
const CkArrayIndex &  idx,
const CkArrayID id,
bool  forceInline = false 
) [inline]

CkCallback::CkCallback ( int  ep,
const CProxyElement_ArrayBase &  arrElt,
bool  forceInline = false 
)

CkCallback::CkCallback ( int  ep,
CProxySection_ArrayBase &  sectElt,
bool  forceInline = false 
)

CkCallback::CkCallback ( int  ep,
CkSectionID sid 
)

CkCallback::CkCallback ( Chare p,
int  ep,
bool  forceInline = false 
)

CkCallback::CkCallback ( Group p,
int  ep,
bool  forceInline = false 
)

CkCallback::CkCallback ( NodeGroup p,
int  ep,
bool  forceInline = false 
)

CkCallback::CkCallback ( ArrayElement p,
int  ep,
bool  forceInline = false 
)

CkCallback::CkCallback ( const CcsDelayedReply reply  )  [inline]

CkCallback::~CkCallback (  )  [inline]

Definition at line 347 of file ckcallback.h.

References thread_destroy().

Here is the call graph for this function:


Member Function Documentation

static const char* CkCallback::typeName ( callbackType  type  )  [inline, static]

bool CkCallback::operator== ( CkCallback other  )  [inline]

Definition at line 149 of file ckcallback.h.

References CkCallback::callbackData::s_section::_elems, CkCallback::callbackData::s_section::_nElems, CkCallback::callbackData::array, bcastArray, bcastGroup, bcastNodeGroup, bcastSection, CkCallback::callbackData::c1fn, call1Fn, callCFn, CkCallback::callbackData::s_thread::cb, CkCallback::callbackData::cfn, CkCallback::callbackData::chare, ckExit, d, CkCallback::callbackData::s_section::ep, CkCallback::callbackData::s_array::ep, CkCallback::callbackData::s_group::ep, CkCallback::callbackData::s_chare::ep, CkCallback::callbackData::s_cfn::fn, CkCallback::callbackData::s_c1fn::fn, CkCallback::callbackData::group, CkCallback::callbackData::s_section::hasRefnum, CkCallback::callbackData::s_array::hasRefnum, CkCallback::callbackData::s_group::hasRefnum, CkCallback::callbackData::s_chare::hasRefnum, CkCallback::callbackData::s_array::id, CkCallback::callbackData::s_group::id, CkCallback::callbackData::s_chare::id, CkCallback::callbackData::s_array::idx, ignore, invalid, isendArray, isendChare, isendGroup, isendNodeGroup, CkCallback::callbackData::s_section::npes, CkCallback::callbackData::s_cfn::onPE, CkCallback::callbackData::s_group::onPE, CkChareID::onPE, CkCallback::callbackData::s_thread::onPE, CkCallback::callbackData::s_cfn::param, CkCallback::callbackData::s_section::pelist, CkCallback::callbackData::s_section::refnum, CkCallback::callbackData::s_array::refnum, CkCallback::callbackData::s_group::refnum, CkCallback::callbackData::s_chare::refnum, replyCCS, resumeThread, CkCallback::callbackData::section, sendArray, sendChare, sendGroup, sendNodeGroup, CkCallback::callbackData::s_section::sinfo, CkCallback::callbackData::thread, and type.

void CkCallback::impl_thread_init ( void   ) 

Definition at line 54 of file ckcallback.C.

References CkCallback::callbackData::s_thread::cb, cb, Converse::CkMyPe(), d, CkCallback::callbackData::s_thread::onPE, CkCallback::callbackData::s_thread::ret, CkCallback::callbackData::s_thread::th, and CkCallback::callbackData::thread.

Referenced by CkCallback().

Here is the call graph for this function:

Here is the caller graph for this function:

void * CkCallback::impl_thread_delay ( void   )  const

bool CkCallback::isInvalid ( void   )  const [inline]

bool CkCallback::requiresMsgConstruction (  )  const [inline]

Definition at line 353 of file ckcallback.h.

References ckExit, ignore, invalid, and type.

Referenced by invokeDestinationCallback(), invokeSourceCallback(), and send().

Here is the caller graph for this function:

bool CkCallback::containsPointer (  )  const

Does this callback point at something that may not be at the same address after a checkpoint/restart cycle?

Definition at line 484 of file ckcallback.C.

References bcastArray, bcastGroup, bcastNodeGroup, bcastSection, call1Fn, callCFn, ckExit, ignore, invalid, isendArray, isendChare, isendGroup, isendNodeGroup, replyCCS, resumeThread, sendArray, sendChare, sendGroup, sendNodeGroup, and type.

Referenced by CkStartCheckpoint().

Here is the caller graph for this function:

void* CkCallback::thread_delay ( void   )  const [inline]

Interface used by threaded callbacks: Libraries should call these from their "start" entry points.

Use "return cb.thread_delay()" to suspend the thread before the return. It's a no-op for everything but threads.

Reimplemented in CkCallbackPython.

Definition at line 368 of file ckcallback.h.

References impl_thread_delay(), resumeThread, and type.

Referenced by CkCallbackResumeThread::~CkCallbackResumeThread().

Here is the call graph for this function:

Here is the caller graph for this function:

void CkCallback::thread_destroy (  )  const

Definition at line 521 of file ckcallback.C.

References CkCallback::callbackData::s_thread::cb, d, resumeThread, CkCallback::callbackData::thread, and type.

Referenced by ~CkCallback(), and CkCallbackResumeThread::~CkCallbackResumeThread().

Here is the caller graph for this function:

void CkCallback::send ( void *  msg = NULL  )  const

Send this message back to the caller.

Libraries should call this from their "done" entry points. It takes the given message and handles it appropriately. After the send(), this callback is finished and cannot be reused.

Definition at line 292 of file ckcallback.C.

References _ckcallbackgroup, CkCallback::callbackData::s_section::_elems, _entryTable, CkCallback::callbackData::s_section::_nElems, CkCallback::callbackData::array, CkArrayIndexBase::asChild(), bcastArray, bcastGroup, bcastNodeGroup, bcastSection, CkCallback::callbackData::c1fn, call1Fn, callCFn, CkCallback::callbackData::s_thread::cb, CkCallback::callbackData::ccsReply, CcsSendDelayedReply(), CkCallback::callbackData::cfn, CkCallback::callbackData::chare, CharmLibInterOperate, CkDataMsg::check(), CkAllocSysMsg(), CkBroadcastMsgArray(), CkBroadcastMsgBranch(), CkBroadcastMsgNodeBranch(), CkBroadcastMsgSection(), CkCallbackSendExt(), CkExit(), ckExit, CkFreeMsg(), Converse::CkMyPe(), CkSendMsg(), CkSendMsgArray(), CkSendMsgArrayInline(), CkSendMsgBranch(), CkSendMsgBranchInline(), CkSendMsgInline(), CkSendMsgNodeBranch(), CkSendMsgNodeBranchInline(), CkSetMsgArrayIfNotThere(), CkSetRefNum(), CmiAbort(), CthAwaken(), d, data, dest, CkCallback::callbackData::s_section::ep, CkCallback::callbackData::s_array::ep, CkCallback::callbackData::s_group::ep, CkCallback::callbackData::s_chare::ep, CkCallback::callbackData::s_cfn::fn, CkCallback::callbackData::s_c1fn::fn, CkDataMsg::getData(), CkDataMsg::getLength(), CkCallback::callbackData::group, CkCallback::callbackData::s_section::hasRefnum, CkCallback::callbackData::s_array::hasRefnum, CkCallback::callbackData::s_group::hasRefnum, CkCallback::callbackData::s_chare::hasRefnum, CkCallback::callbackData::s_array::id, CkCallback::callbackData::s_group::id, CkCallback::callbackData::s_chare::id, CkCallback::callbackData::s_array::idx, ignore, invalid, isCkExtReductionCb, isendArray, isendChare, isendGroup, isendNodeGroup, length, LibCkExit(), PUP::m, CkCallback::callbackData::s_section::npes, CkCallback::callbackData::s_group::onPE, CkCallback::callbackData::s_cfn::onPE, CkCallback::callbackData::s_thread::onPE, CkCallback::callbackData::s_cfn::param, CkCallback::callbackData::s_section::pelist, CkCallback::callbackData::s_section::refnum, CkCallback::callbackData::s_array::refnum, CkCallback::callbackData::s_group::refnum, CkCallback::callbackData::s_chare::refnum, CkCallback::callbackData::s_ccsReply::reply, replyCCS, resumeThread, CkCallback::callbackData::s_thread::ret, CkCallback::callbackData::section, sendArray, sendChare, sendGroup, sendNodeGroup, CkCallback::callbackData::s_section::sinfo, CkCallback::callbackData::s_thread::th, CkCallback::callbackData::thread, and type.

Referenced by _endCheckpointHandler(), AllreduceMgr::allreduce_recieve(), ccsHandlerToCallback(), CkCreateArrayAsync(), CkRestartMain(), CkResumeRestartMain(), CkMemCheckPT::cpFinish(), pathHistoryManager::criticalPathProjectionsDone(), CUDACallbackManager(), pose::exit(), ck::impl::XArraySectionReducer::finalReducer(), CkReductionMgr::finishBarrier(), CkNodeReductionMgr::finishReduction(), CkReductionMgr::finishReduction(), CkNcpyBuffer::get(), CkArray::initDone(), CkMemCheckPT::isMaster(), liveViz0Get(), performEmApiCmaTransfer(), performEmApiMemcpy(), controlPointManager::processControlPoints(), CkNcpyBuffer::put(), CkMulticastMgr::reduceFragment(), idaStarGroup::ReductionResults(), QdCallback::send(), send(), CkCheckpointMgr::SendRestartCB(), pathHistoryManager::traceCriticalPathBackStepByStep(), and taskGraphArray::tryToSolve().

Here is the call graph for this function:

Here is the caller graph for this function:

void CkCallback::send ( int  length,
const void *  data 
) const

Send this data, formatted as a CkDataMsg, back to the caller.

Definition at line 280 of file ckcallback.C.

References CkDataMsg::buildNew(), requiresMsgConstruction(), and send().

Here is the call graph for this function:

void CkCallback::pup ( PUP::er p  ) 

void CkCallback::setRefNum ( CMK_REFNUM_TYPE  refnum  )  [inline]

Definition at line 392 of file ckcallback.h.

References setRefnum().

Here is the call graph for this function:

void CkCallback::setRefnum ( CMK_REFNUM_TYPE  refnum  )  [inline]


Field Documentation

Definition at line 146 of file ckcallback.h.

Referenced by CkExtContributeTo(), and send().


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

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