*** empty log message ***
authorSameer Kumar <skumar2@uiuc.edu>
Thu, 20 May 2004 23:06:46 +0000 (23:06 +0000)
committerSameer Kumar <skumar2@uiuc.edu>
Thu, 20 May 2004 23:06:46 +0000 (23:06 +0000)
src/ck-com/EachToManyMulticastStrategy.C
src/ck-core/ComlibStrategy.C
src/ck-core/ComlibStrategy.h
src/conv-com/convcomlibstrategy.C
src/conv-com/routerstrategy.C

index c1a66a6502dc6ded8b9af22af1cfac41333ce4f1..35dc336d1d64c25e05a7f59d3ff7e9dd1b59e364 100644 (file)
@@ -148,6 +148,7 @@ extern char *router;
 void EachToManyMulticastStrategy::commonInit() {
 
     setBracketed();
+    setForwardOnMigration(1);
 
     if(CkMyPe() == 0 && router != NULL){
         if(strcmp(router, "USE_MESH") == 0)
@@ -220,16 +221,19 @@ void EachToManyMulticastStrategy::pup(PUP::er &p){
     p | routerID; 
     p | npes; p | ndestpes;     
     
-    if(p.isUnpacking()) {
+    if(p.isUnpacking() && npes > 0) {
         pelist = new int[npes];    
     }
-    p(pelist, npes);
 
-    if(p.isUnpacking()) {
+    if(npes > 0)
+        p(pelist, npes);
+
+    if(p.isUnpacking() && ndestpes > 0) {
         destpelist = new int[ndestpes];    
     }    
 
-    p(destpelist, ndestpes);
+    if(ndestpes > 0)
+        p(destpelist, ndestpes);
 
     if(p.isUnpacking()){
        handlerId = CkRegisterHandler((CmiHandler)E2MHandler);
index cbf3a98b49f7304c1e54aacb15922510fad3fbed..fc9fb416b5d7b85c5ced17ff9518f481693cf061 100644 (file)
@@ -17,6 +17,7 @@ void CharmStrategy::pup(PUP::er &p) {
     p | nginfo;
     p | ginfo;
     p | ainfo;
+    p | forwardOnMigration;
 }
 
 CharmMessageHolder::CharmMessageHolder(char * msg, int proc) 
@@ -176,7 +177,7 @@ void ComlibArrayInfo::pup(PUP::er &p){
         dest_elements = NULL;
 
     //Insert all local elements into a vector
-    if(p.isUnpacking()) {
+    if(p.isUnpacking() && !dest_aid.isZero()) {
         CkArray *dest_array = CkArrayID::CkLocalBranch(dest_aid);
         
         if(nDestIndices == 0){            
index 25a9097233d6a194341bf7d8bf518bad0689de84..e33722880e9b5fa45e1898f987f89d068159d594 100644 (file)
@@ -121,9 +121,16 @@ class CharmStrategy : public Strategy {
  public:
     ComlibGroupInfo ginfo;
     ComlibNodeGroupInfo nginfo;
-    ComlibArrayInfo ainfo;    
 
-    CharmStrategy() : Strategy() {setType(GROUP_STRATEGY); forwardOnMigration = 0;}
+    //The communication library array listener watches and monitors
+    //the array elements belonging to ainfo.src_aid
+    ComlibArrayInfo ainfo;
+    
+    CharmStrategy() : Strategy() {
+        setType(GROUP_STRATEGY); 
+        forwardOnMigration = 0;
+    }
+
     CharmStrategy(CkMigrateMessage *m) : Strategy(m){}
 
     //Called for each message
index 636c2dda96e3bafb5ab0953f8d8ea3e8258d59de..72f5cfe58911ac774397a3cf2abe9c5f94683701 100644 (file)
@@ -13,6 +13,7 @@ Strategy::Strategy() : PUP::able() {
     myInstanceID = 0;
     type = CONVERSE_STRATEGY;
     converseStrategy = this;
+    isStrategyBracketed = 0;
 };
 
 //Each strategy must define his own Pup interface.
index 681c795ae68ac8145b10bc1cae95fc481d4c73f7..77a2028d975aca3c9db5b8d6080d250c1272476a 100644 (file)
@@ -114,7 +114,7 @@ RouterStrategy::RouterStrategy(int stratid, int handle, int _npes,
         router = new D3GridRouter(npes, myPe);
         break;
 
-    case USE_DIRECT:
+    case USE_DIRECT: router = NULL;
         break;
         
     default: CmiAbort("Unknown Strategy\n");