PPL Logo

ck Namespace Reference

The class envelope defines a Charm++ message's header. More...


Data Structures

class  ArrayIndexCompressor
class  FixedArrayIndexCompressor
class  ObjID
 The basic element identifier. More...

Namespaces

namespace  impl

Functions

bool operator== (ObjID lhs, ObjID rhs)
bool operator!= (ObjID lhs, ObjID rhs)


Detailed Description

The class envelope defines a Charm++ message's header.

The first 'CmiReservedHeaderSize' bytes of memory is exclusively reserved for Converse header, which is defined in converse.h and platform specific config files.

After Charm++ envelope comes the payload, i.e. a variable-length amount of user data. Following the user data, optionally, a variable number of bits of priority data can be stored at the end. Function envelope::alloc(msgtype,size,prio) is always used to allocate the whole message. Note that this memory layout must be observed.

The following are a few terms that are used often:

 Envelope pointer        \
 Converse message pointer -> [ [ Converse envelope ]       ]
                             [       Charm envelope        ] 
 User message pointer     -> [ User data/payload ... ]
 Priority pointer         -> [ Priority ints ... ]

The "message pointers" passed to and from users bypass the envelope and point directly* to the user data--the routine "EnvToUsr" below adjusts an envelope (or converse message) pointer into this user message pointer. There is a corresponding routine "UsrToEnv" which takes the user data pointer and returns a pointer to the envelope/converse message.

Unfortunately, in the guts of Charm++ it's not always clear whether you've been given a converse or user message pointer, as both tend to be passed as void *. Confusing the two will invariably result in data corruption and bizarre crashes.

FIXME: Make CkMessage inherit from envelope, which would unify converse, envelope, and user message pointers.


Function Documentation

bool ck::operator== ( ObjID  lhs,
ObjID  rhs 
) [inline]

Definition at line 87 of file objid.h.

References ck::ObjID::getID().

Here is the call graph for this function:

bool ck::operator!= ( ObjID  lhs,
ObjID  rhs 
) [inline]

Definition at line 90 of file objid.h.


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