Setting load balancing time for hybrid lb
authorHarshitha <gplkrsh2@illinois.edu>
Fri, 19 Oct 2012 16:04:53 +0000 (11:04 -0500)
committerHarshitha <gplkrsh2@illinois.edu>
Fri, 19 Oct 2012 16:04:53 +0000 (11:04 -0500)
src/ck-ldb/HybridBaseLB.C

index 853acf1d596871d7de207fecdee94eb052fa09a3..8f6fde551ef563768f1b9eb1371b2e8cf346d0c5 100644 (file)
@@ -1145,8 +1145,8 @@ void HybridBaseLB::ResumeClients(int balancing)
 #if CMK_LBDB_ON
   DEBUGF(("[%d] ResumeClients. \n", CkMyPe()));
 
+  double end_lb_time = CkWallTimer();
   if (CkMyPe() == 0 && balancing) {
-    double end_lb_time = CkWallTimer();
     if (_lb_args.debug())
       CkPrintf("[%s] Load balancing step %d finished at %f duration %f\n",
                lbName(), step()-1,end_lb_time,end_lb_time - start_lb_time);
@@ -1156,6 +1156,7 @@ void HybridBaseLB::ResumeClients(int balancing)
   theLbdb->ClearLoads();
 
   theLbdb->ResumeClients();
+       theLbdb->SetMigrationCost(end_lb_time - start_lb_time);
 #endif
 }