PPL Logo

CkLocRec_buffering Class Reference

Buffers messages until record is replaced in the hash table, then delivers all messages to the replacing record. More...

Inheritance diagram for CkLocRec_buffering:

Inheritance graph
[legend]
Collaboration diagram for CkLocRec_buffering:

Collaboration graph
[legend]

Public Member Functions

 CkLocRec_buffering (CkLocMgr *Narr)
virtual ~CkLocRec_buffering ()
virtual RecType type (void)
virtual CmiBool deliver (CkArrayMessage *msg, CkDeliver_t type, int opts=0)
 Accept a message for this element.
virtual void beenReplaced (void)
 This is called when this ArrayRec is about to be replaced.
virtual CmiBool isObsolete (int nSprings, const CkArrayIndex &idx)
 Return if this rec is now obsolete.

Private Attributes

CkQ< CkArrayMessage * > buffer

Detailed Description

Buffers messages until record is replaced in the hash table, then delivers all messages to the replacing record.

This is used when a message arrives for a local element that has not yet been created, buffering messages until the new element finally checks in.

It's silly to send a message to an element you won't ever create, so this kind of record causes an abort "Stale array manager message!" if it's left undelivered too long.

Definition at line 1704 of file cklocation.C.


Constructor & Destructor Documentation

CkLocRec_buffering::CkLocRec_buffering ( CkLocMgr Narr  )  [inline]

Definition at line 1708 of file cklocation.C.

virtual CkLocRec_buffering::~CkLocRec_buffering (  )  [inline, virtual]

Definition at line 1709 of file cklocation.C.

References Converse::CkMyPe().


Member Function Documentation

virtual RecType CkLocRec_buffering::type ( void   )  [inline, virtual]

Implements CkLocRec.

Definition at line 1719 of file cklocation.C.

References CkLocRec::buffering.

virtual CmiBool CkLocRec_buffering::deliver ( CkArrayMessage m,
CkDeliver_t  type,
int  opts = 0 
) [inline, virtual]

Accept a message for this element.

Implements CkLocRec.

Definition at line 1722 of file cklocation.C.

References CkArrayMessage::array_index(), CkCopyMsg(), CmiTrue, idx2str(), opts, envelope::sender, and UsrToEnv().

virtual void CkLocRec_buffering::beenReplaced ( void   )  [inline, virtual]

This is called when this ArrayRec is about to be replaced.

It is only used to deliver buffered element messages.

Reimplemented from CkLocRec.

Definition at line 1737 of file cklocation.C.

References CkArrayMessage::array_index(), CmiMyPe(), CmiPrintf(), CkLocMgr::deliverViaQueue(), CkObjID::getObject(), idx2str(), CkLocRec::myLocMgr, envelope::sender, CkObjID::type, TypeInvalid, and UsrToEnv().

virtual CmiBool CkLocRec_buffering::isObsolete ( int  nSprings,
const CkArrayIndex idx 
) [inline, virtual]

Return if this rec is now obsolete.

Implements CkLocRec_aging.

Definition at line 1757 of file cklocation.C.

References Converse::CkMyPe(), CkPrintEntryMethod(), CmiFalse, idx2str(), CkLocMgr::isHome(), msg, and CkLocRec::myLocMgr.


Field Documentation

Definition at line 1706 of file cklocation.C.


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

Generated on Thu May 24 07:57:21 2012 for Charm++ by  doxygen 1.5.5