cParsimPartition Class Reference
[Parallel simulation support]

Represents one partition in a parallel simulation. More...

#include <cparsimpartition.h>

Inheritance diagram for cParsimPartition:

cPolymorphic List of all members.

Public Member Functions

 cParsimPartition ()
virtual ~cParsimPartition ()
void setContext (cSimulation *sim, cParsimCommunications *comm, cParsimSynchronizer *synch)
void startRun ()
void endRun ()
void shutdown ()
virtual void processOutgoingMessage (cMessage *msg, int procId, int moduleId, int gateId, void *data)
virtual void processReceivedBuffer (cCommBuffer *buffer, int tag, int sourceProcId)
virtual void processReceivedMessage (cMessage *msg, int destModuleId, int destGateId, int sourceProcId)
virtual void broadcastTerminationException (cTerminationException *e)
virtual void broadcastException (cException *e)

Detailed Description

Represents one partition in a parallel simulation.

Knows about partitions and the links between this partition and its neighbours.

Interconnections are stored not directly inside this object, but in cProxyGate's of cPlaceHolderModule's. The remote address fields of cProxyGate's are filled out here in the connectRemoteGates() method.

This layer also handles generic (synchronization-independent part of) communication with other partitions:

This layer is communication library independent (i.e it contains no MPI, PVM, etc. calls) -- it builds on the abstraction layer provided by cParsimCommunications.


Constructor & Destructor Documentation

cParsimPartition::cParsimPartition  ) 
 

Constructor.

virtual cParsimPartition::~cParsimPartition  )  [virtual]
 

Virtual destructor.


Member Function Documentation

virtual void cParsimPartition::broadcastException cException e  )  [virtual]
 

Called when a cException occurs (i.e.

the simulation is about to be stopped with an error), this methods notifies other partitions about the exception.

This methods "eats" exceptions that occur during broadcast. (We're not interested in stacked exceptions.)

virtual void cParsimPartition::broadcastTerminationException cTerminationException e  )  [virtual]
 

Called when a cTerminationException occurs (i.e.

the simulation is about to be finished normally), this methods notifies other partitions about the exception.

This methods "eats" exceptions that occur during broadcast. (We're not interested in stacked exceptions.)

void cParsimPartition::endRun  ) 
 

Called at the end of a simulation run.

virtual void cParsimPartition::processOutgoingMessage cMessage msg,
int  procId,
int  moduleId,
int  gateId,
void *  data
[virtual]
 

A hook called from cProxyGate::deliver() when an outgoing cMessage arrives at partition boundary.

We just pass it up to the synchronization layer (see similar method in cParsimSynchronizer).

virtual void cParsimPartition::processReceivedBuffer cCommBuffer buffer,
int  tag,
int  sourceProcId
[virtual]
 

Process messages coming from other partitions.

This method is called from the synchronization layer (see cParsimSynchronizer), after it has processed all tags that it understands (namely, cMessages (tag=TAG_CMESSAGE) and all tags used by the synchronization protocol).

virtual void cParsimPartition::processReceivedMessage cMessage msg,
int  destModuleId,
int  destGateId,
int  sourceProcId
[virtual]
 

Process cMessages received from other partitions.

This method is called from the synchronization layer (see cParsimSynchronizer) when it received a message from other partitions. This method checks that the destination module/gate still exists, sets the source module/gate to the appropriate placeholder module, and inserts the message into the FES.

void cParsimPartition::setContext cSimulation sim,
cParsimCommunications comm,
cParsimSynchronizer synch
 

Pass cParsimPartition the objects it has to cooperate with.

void cParsimPartition::shutdown  ) 
 

Shut down the parallel simulation system.

void cParsimPartition::startRun  ) 
 

Called at the beginning of a simulation run.

Fills in remote gate addresses of all cProxyGate's in the current partition.


The documentation for this class was generated from the following file:
Generated on Sat Oct 21 17:48:01 2006 for OMNeT++ Parallel Simulation Support by  doxygen 1.4.6