PPL Logo

CkRegister

Charm Registration--keeps track of the possible chare and method types. More...

Data Structures

class  EntryInfo
 Represents a single entry method or constructor. More...
class  MsgInfo
 Represents one type of Message. More...
class  ChareInfo
 Represents a class of Chares (or array or group elements). More...
class  MainInfo
 Describes a mainchare's constructor. These are all executed at startup. More...
class  ReadonlyInfo
 Describes a readonly global variable. More...
class  ReadonlyMsgInfo
 Describes a readonly message. More...
class  CkRegisteredInfo< T >
 This class stores registered entities, like EntryInfo's, in a linear list indexed by index ("idx"). More...

Typedefs

typedef void *(* CkPackFnPtr )(void *msg)
 Message pack function: convert a message into a buffer.
typedef void *(* CkUnpackFnPtr )(void *buf)
 Message unpack function: convert a buffer into a message.
typedef void(* CkDeallocFnPtr )(void *msg)
 Message dealloc function: deletes a message.
typedef void(* CkCallFnPtr )(void *msg, void *obj)
 A "call function" to invoke a method on an object.
typedef void(* CkPupReadonlyFnPtr )(void *pup_er)
 This function pup's a global variable.
typedef int(* CkMarshallUnpackFn )(char *marshall_buf, void *object)
 A "marshall unpack" function: pups out parameters and calls a method.
typedef void(* CkMessagePupFn )(PUP::er &p, void *userMessage)
 A "message pup" function: pups message data for debugger display.

Enumerations

enum  ChareType {
  TypeInvalid = 0, TypeChare, TypeMainChare, TypeGroup,
  TypeNodeGroup, TypeArray, TypeSection, TypeInvalid = 0,
  TypeChare, TypeMainChare, TypeGroup, TypeNodeGroup,
  TypeArray
}
 type of a chare More...
enum  ChareType {
  TypeInvalid = 0, TypeChare, TypeMainChare, TypeGroup,
  TypeNodeGroup, TypeArray, TypeSection, TypeInvalid = 0,
  TypeChare, TypeMainChare, TypeGroup, TypeNodeGroup,
  TypeArray
}

Functions

int CkRegisterMsg (const char *name, CkPackFnPtr pack, CkUnpackFnPtr unpack, CkDeallocFnPtr dealloc, size_t size)
 Register this message name, with this basic size and pack and unpack functions.
int CkRegisterEp (const char *name, CkCallFnPtr call, int msgIdx, int chareIdx, int ck_ep_flags)
 Register this entry point, with this call function and flags.
int CkRegisterEpTemplated (const char *name, CkCallFnPtr call, int msgIdx, int chareIdx, int ck_ep_flags)
int CkRegisterChare (const char *name, size_t dataSz, ChareType chareType)
 Register this type of chare (group, or array), with this size.
void CkRegisterArrayDimensions (int chareIndex, int ndims)
 Register number of array dimensions for this chare array.
void CkRegisterChareInCharm (int chareIndex)
 Register this chare as internal to Charm++.
int CkRegisterMainChare (int chareIndex, int epIndex)
 Register this chare as a mainchare, with this entry point as its constructor.
void CkRegisterMainChareExt (const char *s, int numEntryMethods, int *chareIdx, int *startEpIdx)
void CkRegisterDefaultCtor (int chareIndex, int ctorEpIndex)
 Register a default constructor for this chare.
void CkRegisterMigCtor (int chareIndex, int ctorEpIndex)
 Register a migration constructor for this chare.
void CkRegisterGroupIrr (int chareIndex, int isIrr)
 Indicate whether this group is an IrrGroup.
void CkRegisterGroupExt (const char *s, int numEntryMethods, int *chareIdx, int *startEpIdx)
void CkRegisterArrayMapExt (const char *s, int numEntryMethods, int *chareIdx, int *startEpIdx)
void CkRegisterArrayExt (const char *s, int numEntryMethods, int *chareIdx, int *startEpIdx)
void CkRegisterBase (int derivedIdx, int baseIdx)
 Register the chare baseIdx as a base class of the chare derivedIdx.
void CkRegisterReadonly (const char *name, const char *type, size_t size, void *ptr, CkPupReadonlyFnPtr pup_fn)
 Register this readonly global variable.
void CkRegisterReadonlyExt (const char *name, const char *type, size_t msgSize, char *msg)
void CkRegisterReadonlyMsg (const char *name, const char *type, void **pMsg)
 Register this readonly message.
void CkRegisterMarshallUnpackFn (int epIndex, CkMarshallUnpackFn m)
 Register this marshall unpack function with this entry point.
CkMarshallUnpackFn CkLookupMarshallUnpackFn (int epIndex)
 Lookup the marshall unpack function, if any, for this entry point.
void CkRegisterMessagePupFn (int epIndex, CkMessagePupFn m)
 Register this message pup function with this entry point.
void _registerInit (void)
void _registerDone (void)
int CkGetChareIdx (const char *name)

Variables

CkRegisteredInfo< EntryInfo_entryTable
 These tables are shared between all processors on a node.
CkRegisteredInfo< MsgInfo_msgTable
CkRegisteredInfo< ChareInfo_chareTable
CkRegisteredInfo< MainInfo_mainTable
CkRegisteredInfo< ReadonlyInfo_readonlyTable
CkRegisteredInfo< ReadonlyMsgInfo_readonlyMsgs

Detailed Description

Charm Registration--keeps track of the possible chare and method types.

These routines keep track of the various chares (see ChareInfo and the _chareTable in register.h) and entry methods (see EntryInfo and the _entryTable) that exist in the program.

These are implemented in register.C.

These routines are normally called by a translator-generated _registerModule routine in the .def file. Because these routines fill out global tables, they are normally called exactly once per node at Charm startup time.


Typedef Documentation

typedef void*(* CkPackFnPtr)(void *msg)

Message pack function: convert a message into a buffer.

Definition at line 149 of file charm.h.

typedef void*(* CkUnpackFnPtr)(void *buf)

Message unpack function: convert a buffer into a message.

Definition at line 151 of file charm.h.

typedef void(* CkDeallocFnPtr)(void *msg)

Message dealloc function: deletes a message.

Definition at line 153 of file charm.h.

typedef void(* CkCallFnPtr)(void *msg, void *obj)

A "call function" to invoke a method on an object.

See EntryInfo

Definition at line 192 of file charm.h.

typedef void(* CkPupReadonlyFnPtr)(void *pup_er)

This function pup's a global variable.

Definition at line 223 of file charm.h.

typedef int(* CkMarshallUnpackFn)(char *marshall_buf, void *object)

A "marshall unpack" function: pups out parameters and calls a method.

Definition at line 233 of file charm.h.

typedef void(* CkMessagePupFn)(PUP::er &p, void *userMessage)

A "message pup" function: pups message data for debugger display.

Definition at line 241 of file charm.h.


Enumeration Type Documentation

enum ChareType

type of a chare

Enumerator:
TypeInvalid 
TypeChare 
TypeMainChare 
TypeGroup 
TypeNodeGroup 
TypeArray 
TypeSection 
TypeInvalid 
TypeChare 
TypeMainChare 
TypeGroup 
TypeNodeGroup 
TypeArray 

Definition at line 171 of file charm.h.

enum ChareType

Enumerator:
TypeInvalid 
TypeChare 
TypeMainChare 
TypeGroup 
TypeNodeGroup 
TypeArray 
TypeSection 
TypeInvalid 
TypeChare 
TypeMainChare 
TypeGroup 
TypeNodeGroup 
TypeArray 

Definition at line 181 of file charm.h.


Function Documentation

int CkRegisterMsg ( const char *  name,
CkPackFnPtr  pack,
CkUnpackFnPtr  unpack,
CkDeallocFnPtr  dealloc,
size_t  size 
)

Register this message name, with this basic size and pack and unpack functions.

Definition at line 33 of file register.C.

References CkRegisteredInfo< T >::add().

Referenced by _initCharm(), CpdBreakPointInit(), RegisterCkLoopHdlrs(), and traceCommonInit().

Here is the call graph for this function:

Here is the caller graph for this function:

int CkRegisterEp ( const char *  name,
CkCallFnPtr  call,
int  msgIdx,
int  chareIdx,
int  ck_ep_flags 
)

Register this entry point, with this call function and flags.

Returns the entry point's index in the _entryTable.

Definition at line 72 of file register.C.

References CkRegisterEpInternal().

Here is the call graph for this function:

int CkRegisterEpTemplated ( const char *  name,
CkCallFnPtr  call,
int  msgIdx,
int  chareIdx,
int  ck_ep_flags 
)

Definition at line 77 of file register.C.

References CkRegisterEpInternal().

Referenced by CkRegisterEp().

Here is the call graph for this function:

Here is the caller graph for this function:

int CkRegisterChare ( const char *  name,
size_t  dataSz,
ChareType  chareType 
)

Register this type of chare (group, or array), with this size.

Returns the Chare's index in the _chareTable.

Definition at line 82 of file register.C.

References CkRegisteredInfo< T >::add().

Referenced by _initCharm(), CkRegisterArrayExt(), CkRegisterArrayMapExt(), CkRegisterGroupExt(), CkRegisterMainChareExt(), CpdBreakPointInit(), RegisterCkLoopHdlrs(), and traceCommonInit().

Here is the call graph for this function:

Here is the caller graph for this function:

void CkRegisterArrayDimensions ( int  chareIndex,
int  ndims 
)

Register number of array dimensions for this chare array.

Definition at line 87 of file register.C.

void CkRegisterChareInCharm ( int  chareIndex  ) 

Register this chare as internal to Charm++.

Definition at line 91 of file register.C.

Referenced by _initCharm(), CpdBreakPointInit(), RegisterCkLoopHdlrs(), and traceCommonInit().

Here is the caller graph for this function:

int CkRegisterMainChare ( int  chareIndex,
int  epIndex 
)

Register this chare as a mainchare, with this entry point as its constructor.

Definition at line 162 of file register.C.

References CkRegisteredInfo< T >::add().

Referenced by CkRegisterMainChareExt().

Here is the call graph for this function:

Here is the caller graph for this function:

void CkRegisterMainChareExt ( const char *  s,
int  numEntryMethods,
int chareIdx,
int startEpIdx 
)

void CkRegisterDefaultCtor ( int  chareIndex,
int  ctorEpIndex 
)

Register a default constructor for this chare.

Definition at line 153 of file register.C.

Referenced by CkRegisterArrayExt(), CkRegisterArrayMapExt(), and CkRegisterGroupExt().

Here is the caller graph for this function:

void CkRegisterMigCtor ( int  chareIndex,
int  ctorEpIndex 
)

Register a migration constructor for this chare.

Definition at line 157 of file register.C.

Referenced by CkRegisterArrayExt().

Here is the caller graph for this function:

void CkRegisterGroupIrr ( int  chareIndex,
int  isIrr 
)

Indicate whether this group is an IrrGroup.

Definition at line 95 of file register.C.

Referenced by CkRegisterArrayMapExt(), and CkRegisterGroupExt().

Here is the caller graph for this function:

void CkRegisterGroupExt ( const char *  s,
int  numEntryMethods,
int chareIdx,
int startEpIdx 
)

void CkRegisterArrayMapExt ( const char *  s,
int  numEntryMethods,
int chareIdx,
int startEpIdx 
)

void CkRegisterArrayExt ( const char *  s,
int  numEntryMethods,
int chareIdx,
int startEpIdx 
)

void CkRegisterBase ( int  derivedIdx,
int  baseIdx 
)

Register the chare baseIdx as a base class of the chare derivedIdx.

Definition at line 186 of file register.C.

Referenced by CkRegisterArrayExt(), CkRegisterArrayMapExt(), CkRegisterGroupExt(), and CkRegisterMainChareExt().

Here is the caller graph for this function:

void CkRegisterReadonly ( const char *  name,
const char *  type,
size_t  size,
void *  ptr,
CkPupReadonlyFnPtr  pup_fn 
)

Register this readonly global variable.

Definition at line 200 of file register.C.

References CkRegisteredInfo< T >::add().

Referenced by CkRegisterReadonlyExt(), readonly< dtype >::readonly(), and roarray< dtype, len >::roarray().

Here is the call graph for this function:

Here is the caller graph for this function:

void CkRegisterReadonlyExt ( const char *  name,
const char *  type,
size_t  msgSize,
char *  msg 
)

Definition at line 206 of file register.C.

References ReadOnlyExt::_roPup(), CkRegisterReadonly(), ReadOnlyExt::ro_data, and ReadOnlyExt::setData().

Here is the call graph for this function:

void CkRegisterReadonlyMsg ( const char *  name,
const char *  type,
void **  pMsg 
)

Register this readonly message.

Definition at line 211 of file register.C.

References CkRegisteredInfo< T >::add().

Referenced by romsg< dtype >::romsg().

Here is the call graph for this function:

Here is the caller graph for this function:

void CkRegisterMarshallUnpackFn ( int  epIndex,
CkMarshallUnpackFn  m 
)

Register this marshall unpack function with this entry point.

Definition at line 217 of file register.C.

CkMarshallUnpackFn CkLookupMarshallUnpackFn ( int  epIndex  ) 

Lookup the marshall unpack function, if any, for this entry point.

Definition at line 222 of file register.C.

void CkRegisterMessagePupFn ( int  epIndex,
CkMessagePupFn  m 
)

Register this message pup function with this entry point.

Definition at line 226 of file register.C.

Referenced by CkRegisterMainChareExt().

Here is the caller graph for this function:

void _registerInit ( void   ) 

Definition at line 27 of file register.C.

References __registerDone.

Referenced by _initCharm().

Here is the caller graph for this function:

void _registerDone ( void   ) 

Definition at line 296 of file register.C.

References __registerDone, BGConverse::CkMyRank(), CpdCharmInit(), CpdListRegister(), pupChare(), pupEntry(), pupMain(), pupMsg(), pupReadonly(), and pupReadonlyMsg().

Referenced by _initCharm().

Here is the call graph for this function:

Here is the caller graph for this function:

int CkGetChareIdx ( const char *  name  ) 

Definition at line 192 of file register.C.

References CkRegisteredInfo< T >::size().

Here is the call graph for this function:


Variable Documentation

These tables are shared between all processors on a node.

Definition at line 18 of file register.C.

Referenced by _allocNewChare(), _createGroup(), _initCharm(), _invokeEntry(), _processForPlainChareMsg(), CkLocMgr::addElementToRec(), ampiNodeInit(), automaticallySetMessagePriority(), TraceSummary::beginExecute(), CkArray::broadcastHomeElements(), CkCallback::CkCallback(), CkCreateChare(), CkCreateGroup(), CkCreateLocalGroup(), CkCreateLocalNodeGroup(), CkCreateNodeGroup(), CkDeliverMessageFree(), CkDeliverMessageReadonly(), CkPupMainChareData(), CkPupMessage(), collideNodeInit(), CpdAfterEp(), CpdBeforeEp(), CpdFinishInitialization(), CpdIsBgCharmDebugMessage(), CpdIsCharmDebugMessage(), CpdPupMessage(), CpdRemoveAllBreakPoints(), CpdRemoveBreakPoint(), CpdSetBreakPoint(), criticalPath_setep(), criticalPath_start(), CkLocMgr::demandCreateElement(), TraceSummary::endExecute(), TraceCounter::endOverview(), KMeansBOC::flushCheckDone(), KMeansBOC::getNextPhaseMetrics(), TraceUtilization::initMem(), SumLogPool::initMem(), CkArray::insertElement(), CkLocRec::invokeEntry(), isCharmEnvelope(), PhaseEntry::PhaseEntry(), printEPInfo(), LogEntry::pup(), CProxy::pup(), CkLocMgr::pupElementsFor(), pathHistoryManager::saveCriticalPathForPriorities(), CkCallback::send(), CkLocMgr::sendMsg(), CkMulticastMgr::sendToLocal(), startEntryEvent(), traceCommonInit(), PhaseEntry::write(), TraceSummaryBOC::write(), SumLogPool::write(), CountLogPool::write(), StatTable::write(), and CountLogPool::writeSts().

Definition at line 22 of file register.C.

Referenced by _processRODataMsg(), _sendReadonlies(), bdcastRO(), and CkPupROData().

Definition at line 23 of file register.C.

Referenced by _processROMsgMsg(), _sendReadonlies(), and CkPupROData().


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