
#include <dummyconversestrategy.h>


Public Member Functions | |
| RouterStrategy () | |
| RouterStrategy (CkMigrateMessage *m) | |
| void | insertMessage (MessageHolder *msg) |
| Receive a message from the upper layer and buffer it in the msgQ until doneInserting is called. | |
| void | doneInserting () |
| Called after all messages have been deposited in this processor. | |
| virtual void | pup (PUP::er &p) |
| Each strategy must define his own Pup interface. | |
| PUPable_decl (RouterStrategy) | |
| RouterStrategy (int stratid, int handle, int nsrc, int *srclist, int ndest=0, int *destlist=0) | |
| Constructor. | |
| RouterStrategy (CkMigrateMessage *m) | |
| void | setupRouter () |
| ~RouterStrategy () | |
| Router * | getRouter () |
| comID & | getComID () |
| virtual void | insertMessage (MessageHolder *msg) |
| Called for each message. | |
| virtual void | doneInserting () |
| Called after all messages have been deposited in this processor. | |
| virtual void | handleMessage (void *m) |
| This function is not used since the Router uses its own handlers. | |
| virtual void | deliver (char *, int) |
| This method can be used to deliver a message through the correct class. | |
| void | bracketedUpdatePeKnowledge (int *count) |
| Update the router accordingly to the new information. | |
| virtual void | notifyDone () |
| Called when a subsystem scheme (like in bracketed EachToMany) terminates the requested routing operation. | |
| int * | getProcMap () |
| virtual void | pup (PUP::er &p) |
| Each strategy must define his own Pup interface. | |
| PUPable_decl (RouterStrategy) | |
Protected Member Functions | |
| RouterStrategy (int stratid) | |
| Used only by subclasses to initialize partially. | |
| char | isAllToAll () |
Protected Attributes | |
| int | routerIDsaved |
| Type of subsystem specified for the strategy, routerID can become USE_DIRECT if no objects are local, but then it can become again what required. | |
Private Member Functions | |
| void | setReverseMap () |
Private Attributes | |
| Router * | router |
| CkQ< MessageHolder * > | msgQ |
| CkQ< char * > | recvQ |
| CkQ< char * > | procQ |
| CkQ< DummyMsg * > | dummyQ |
| comID | id |
| int * | pelist |
| A list of all the processors involved in the operation, used when sending direcly without routing. | |
| int | npes |
| Size of pelist. | |
| int * | srcPelist |
| A sublist of pelist containing only processors which are source. | |
| int | nsrcPes |
| Size of srcPelist. | |
| int * | destPelist |
| A sublist of pelist containing only processors which are destination. | |
| int | ndestPes |
| size of destPelist | |
| int * | procMap |
| A list of size CkNumPes() which associate each processor number with the position it occupies in pelist (basically procMap[i]=pelist.indexOf(i)). | |
| int * | bcast_pemap |
| A simple array of size npes, where bcast_pemap[i]=i. | |
| int | myPe |
| Position occupied by this processor in the list of processors currently involved in this operation. | |
| int | routerID |
| Type of Router used by the strategy as subsystem. | |
| int | doneHandle |
| int | doneFlag |
| int | bufferedDoneInserting |
| int * | newKnowledge |
| The processor list used to update the knowledge of the strategy is stored here if when it is delivered there is still an operation in execution. | |
| int | newKnowledgeSize |
| Size of newKnowledge when it is in use. | |
| int * | newKnowledgeSrc |
| Similar to newKnowledge only for the source list. | |
| int | newKnowledgeSrcSize |
| Size of newKnowledgeSrc when it is in use. | |
| int * | newKnowledgeDest |
| Similar to newKnowledge only for the destination list. | |
| int | newKnowledgeDestSize |
| Size of newKnowledgeDest when it is in use. | |
Developed to be called from Converse and from Charm through inheritance by high level strategies.
Strategy optimizes all-to-all communication. It combines messages and sends them along virtual topologies 2d mesh, 3d mesh and hypercube routers.
For large messages send them directly.
Sameer Kumar 05/14/04
Definition at line 15 of file dummyconversestrategy.h.
| RouterStrategy::RouterStrategy | ( | ) |
| RouterStrategy::RouterStrategy | ( | CkMigrateMessage * | m | ) | [inline] |
Definition at line 18 of file dummyconversestrategy.h.
| RouterStrategy::RouterStrategy | ( | CkMigrateMessage * | m | ) | [inline] |
| RouterStrategy::PUPable_decl | ( | RouterStrategy | ) |
| char RouterStrategy::isAllToAll | ( | ) | [inline, protected] |
Definition at line 101 of file routerstrategy.h.
Referenced by EachToManyMulticastStrategy::deliver().
| Router* RouterStrategy::getRouter | ( | ) | [inline] |
Definition at line 120 of file routerstrategy.h.
References router.
Referenced by routerDummyMsg(), routerProcManyCombinedMsg(), and routerRecvManyCombinedMsg().
| comID& RouterStrategy::getComID | ( | ) | [inline] |
Definition at line 121 of file routerstrategy.h.
References id.
Referenced by routerProcManyCombinedMsg(), and routerRecvManyCombinedMsg().
| virtual void RouterStrategy::insertMessage | ( | MessageHolder * | msg | ) | [virtual] |
| virtual void RouterStrategy::doneInserting | ( | void | ) | [virtual] |
Called after all messages have been deposited in this processor.
This corresponds to a call to ComlibEnd(cinst), where cinst is the ComlibInstanceHandle returned when registering the Strategy with Comlib. In higher levels this may need many ComlibEnd calls before invoking doneInserting.
Reimplemented from Strategy.
| virtual void RouterStrategy::handleMessage | ( | void * | m | ) | [inline, virtual] |
This function is not used since the Router uses its own handlers.
Implements Strategy.
Reimplemented in EachToManyMulticastStrategy.
Definition at line 129 of file routerstrategy.h.
References CmiAbort().
| int* RouterStrategy::getProcMap | ( | ) | [inline] |
| virtual void RouterStrategy::pup | ( | PUP::er & | p | ) | [virtual] |
Each strategy must define his own Pup interface.
Reimplemented from Strategy.
Reimplemented in EachToManyMulticastStrategy.
| RouterStrategy::PUPable_decl | ( | RouterStrategy | ) |
Router* RouterStrategy::router [private] |
Definition at line 35 of file routerstrategy.h.
Referenced by doneInserting(), getRouter(), pup(), RouterStrategy(), setupRouter(), and ~RouterStrategy().
CkQ<MessageHolder *> RouterStrategy::msgQ [private] |
CkQ<char *> RouterStrategy::recvQ [private] |
Definition at line 37 of file routerstrategy.h.
CkQ<char *> RouterStrategy::procQ [private] |
Definition at line 37 of file routerstrategy.h.
CkQ<DummyMsg *> RouterStrategy::dummyQ [private] |
Definition at line 38 of file routerstrategy.h.
comID RouterStrategy::id [private] |
int* RouterStrategy::pelist [private] |
A list of all the processors involved in the operation, used when sending direcly without routing.
This array is shared with the router.
Definition at line 43 of file routerstrategy.h.
Referenced by pup(), RouterStrategy(), setReverseMap(), setupRouter(), and ~RouterStrategy().
int RouterStrategy::npes [private] |
Size of pelist.
Definition at line 45 of file routerstrategy.h.
Referenced by insertMessage(), pup(), setReverseMap(), and setupRouter().
int* RouterStrategy::srcPelist [private] |
A sublist of pelist containing only processors which are source.
Definition at line 47 of file routerstrategy.h.
Referenced by pup(), setupRouter(), and ~RouterStrategy().
int RouterStrategy::nsrcPes [private] |
Size of srcPelist.
Definition at line 49 of file routerstrategy.h.
Referenced by pup(), and setupRouter().
int* RouterStrategy::destPelist [private] |
A sublist of pelist containing only processors which are destination.
Definition at line 51 of file routerstrategy.h.
Referenced by insertMessage(), pup(), setupRouter(), and ~RouterStrategy().
int RouterStrategy::ndestPes [private] |
size of destPelist
Definition at line 53 of file routerstrategy.h.
Referenced by insertMessage(), pup(), and setupRouter().
int* RouterStrategy::procMap [private] |
A list of size CkNumPes() which associate each processor number with the position it occupies in pelist (basically procMap[i]=pelist.indexOf(i)).
Definition at line 57 of file routerstrategy.h.
Referenced by getProcMap(), insertMessage(), pup(), RouterStrategy(), setReverseMap(), and ~RouterStrategy().
int* RouterStrategy::bcast_pemap [private] |
A simple array of size npes, where bcast_pemap[i]=i.
Definition at line 59 of file routerstrategy.h.
Referenced by insertMessage(), pup(), RouterStrategy(), setupRouter(), and ~RouterStrategy().
int RouterStrategy::myPe [private] |
Position occupied by this processor in the list of processors currently involved in this operation.
Definition at line 62 of file routerstrategy.h.
Referenced by doneInserting(), setReverseMap(), and setupRouter().
int RouterStrategy::routerID [private] |
Type of Router used by the strategy as subsystem.
Definition at line 64 of file routerstrategy.h.
Referenced by doneInserting(), insertMessage(), and setupRouter().
int RouterStrategy::doneHandle [private] |
Definition at line 66 of file routerstrategy.h.
Referenced by notifyDone(), pup(), and RouterStrategy().
int RouterStrategy::doneFlag [private] |
Definition at line 70 of file routerstrategy.h.
Referenced by bracketedUpdatePeKnowledge(), doneInserting(), notifyDone(), pup(), and RouterStrategy().
int RouterStrategy::bufferedDoneInserting [private] |
Definition at line 70 of file routerstrategy.h.
Referenced by doneInserting(), notifyDone(), pup(), and RouterStrategy().
int* RouterStrategy::newKnowledge [private] |
The processor list used to update the knowledge of the strategy is stored here if when it is delivered there is still an operation in execution.
In this case we have to wait for it to finish, and then proceed to update the Router.
Definition at line 76 of file routerstrategy.h.
Referenced by bracketedUpdatePeKnowledge(), notifyDone(), pup(), RouterStrategy(), and setupRouter().
int RouterStrategy::newKnowledgeSize [private] |
Size of newKnowledge when it is in use.
Definition at line 78 of file routerstrategy.h.
Referenced by bracketedUpdatePeKnowledge(), pup(), RouterStrategy(), and setupRouter().
int* RouterStrategy::newKnowledgeSrc [private] |
Similar to newKnowledge only for the source list.
Definition at line 80 of file routerstrategy.h.
Referenced by bracketedUpdatePeKnowledge(), pup(), RouterStrategy(), and setupRouter().
int RouterStrategy::newKnowledgeSrcSize [private] |
Size of newKnowledgeSrc when it is in use.
Definition at line 82 of file routerstrategy.h.
Referenced by bracketedUpdatePeKnowledge(), pup(), RouterStrategy(), and setupRouter().
int* RouterStrategy::newKnowledgeDest [private] |
Similar to newKnowledge only for the destination list.
Definition at line 84 of file routerstrategy.h.
Referenced by bracketedUpdatePeKnowledge(), pup(), RouterStrategy(), and setupRouter().
int RouterStrategy::newKnowledgeDestSize [private] |
Size of newKnowledgeDest when it is in use.
Definition at line 86 of file routerstrategy.h.
Referenced by bracketedUpdatePeKnowledge(), pup(), RouterStrategy(), and setupRouter().
int RouterStrategy::routerIDsaved [protected] |
Type of subsystem specified for the strategy, routerID can become USE_DIRECT if no objects are local, but then it can become again what required.
Definition at line 99 of file routerstrategy.h.
Referenced by EachToManyMulticastStrategy::commonInit(), pup(), RouterStrategy(), and setupRouter().
1.5.5