PPL Logo

MetaBalancer Class Reference

#include <MetaBalancer.h>

Inheritance diagram for MetaBalancer:

Inheritance graph
[legend]
Collaboration diagram for MetaBalancer:

Collaboration graph
[legend]
void pup (PUP::er &p)
void ResumeClients ()
void ResetAdaptive ()
int get_iteration ()
int get_finished_iteration ()
void ContributeStats (int iteration)
void AdjustCountForDeadContributor (int iteration)
void AdjustCountForNewContributor (int iteration)
bool AddLoad (int iteration, double load)
void SetCharePupSize (size_t psize)
void ReceiveMinStats (double *load, int n)
void TriggerSoon (int iteration_no, double imbalance_ratio, double tolerate_imb)
void LoadBalanceDecision (int, int)
void LoadBalanceDecisionFinal (int, int)
void MetaLBCallLBOnChares ()
void MetaLBSetLBOnChares (int switchFrom, int switchTo)
void ReceiveIterationNo (int)
void HandleAdaptiveNoObj ()
void RegisterNoObjCallback (int index)
void TriggerAdaptiveReduction ()
void PreviousAvgLoad (double avg)
bool generatePlan (int &period, double &ratio_at_t)
bool getLineEq (double new_load_percent, double &aslope, double &ac, double &mslope, double &mc)
bool getPeriodForLinear (double a, double b, double c, int &period)
bool getPeriodForStrategy (double new_load, double overhead_percent, int &period, double &ratio_at_t)
int getPredictedLBPeriod (bool &is_tentative)
bool isStrategyComm ()
void UpdateAfterLBData (int is_lb_refine, double lb_max, double lb_avg, double local_comm, double remote_comm)
void UpdateAfterLBData (double max_load, double max_cpu, double avg_load)
void UpdateAfterLBComm (double alpha_beta_cost)
void GetPrevLBData (int &lb_type, double &lb_max_avg_ratio, double &local_remote_comm_ratio)
void GetLBDataForLB (int lb_type, double &lb_max_avg_ratio, double &local_remote_comm_ratio)
void SetMigrationCost (double lb_migration_cost)
void SetStrategyCost (double lb_strategy_cost)
void init ()
static void initnodeFn (void)
static void periodicCall (void *ad)
static void checkForNoObj (void *ad)

Public Member Functions

 MetaBalancer (void)
 MetaBalancer (CkMigrateMessage *m)
 ~MetaBalancer ()

Static Public Member Functions

static MetaBalancerObject ()

Data Fields

bool lb_in_progress

Private Attributes

MetaBalancerRednmetaRdnGroup
LBDatabaselbdatabase
std::vector< double > total_load_vec
std::vector< inttotal_count_vec
std::vector< double > max_load_vec
std::vector< double > min_load_vec
std::vector< intlbdb_no_obj_callback
double prev_idle
double alpha_beta_cost_to_load
int is_prev_lb_refine
int prev_bytes
int prev_msgs
int prev_outsidepemsgs
int prev_outsidepebytes
int prev_hops
int prev_hopbytes
bool print_iteration_time
double prev_iteration_time
double prev_avg_load
int chare_pup_size
double pe_ld_kurtosis
double pe_ld_skewness
int total_ovld_pes
int current_balancer
ForestModelrFmodel
struct
MetaBalancer::AdaptiveMetaBalancer 
adaptive_lbdb
struct
MetaBalancer::AdaptiveLBStructure 
adaptive_struct

Data Structures

struct  AdaptiveData
struct  AdaptiveLBInfo
struct  AdaptiveLBStructure
struct  AdaptiveMetaBalancer

Detailed Description

Definition at line 87 of file MetaBalancer.h.


Constructor & Destructor Documentation

MetaBalancer::MetaBalancer ( void   )  [inline]

Definition at line 89 of file MetaBalancer.h.

References init().

Here is the call graph for this function:

MetaBalancer::MetaBalancer ( CkMigrateMessage m  )  [inline]

Definition at line 90 of file MetaBalancer.h.

References init().

Here is the call graph for this function:

MetaBalancer::~MetaBalancer (  )  [inline]

Definition at line 91 of file MetaBalancer.h.

References Converse::CkMyPe(), and rFmodel.

Here is the call graph for this function:


Member Function Documentation

void MetaBalancer::init ( void   )  [private]

static MetaBalancer* MetaBalancer::Object (  )  [inline, static]

Definition at line 100 of file MetaBalancer.h.

References CkLocalBranch().

Referenced by MetaBalancerObj().

Here is the call graph for this function:

Here is the caller graph for this function:

void MetaBalancer::initnodeFn ( void   )  [static]

Definition at line 118 of file MetaBalancer.C.

void MetaBalancer::pup ( PUP::er p  ) 

void MetaBalancer::ResumeClients ( void   ) 

void MetaBalancer::ResetAdaptive (  ) 

Definition at line 964 of file MetaBalancer.C.

References adaptive_lbdb, lb_in_progress, and MetaBalancer::AdaptiveMetaBalancer::lb_iter_no.

Referenced by LBDatabase::ResetAdaptive().

Here is the caller graph for this function:

int MetaBalancer::get_iteration (  ) 

Definition at line 230 of file MetaBalancer.C.

References adaptive_struct, and MetaBalancer::AdaptiveLBStructure::lb_iteration_no.

Referenced by CkMigratable::commonInit().

Here is the caller graph for this function:

int MetaBalancer::get_finished_iteration (  ) 

Definition at line 234 of file MetaBalancer.C.

References adaptive_struct, and MetaBalancer::AdaptiveLBStructure::finished_iteration_no.

Referenced by AdjustCountForDeadContributor(), AdjustCountForNewContributor(), and CkMigratable::AtSync().

Here is the caller graph for this function:

void MetaBalancer::ContributeStats ( int  iteration  ) 

void MetaBalancer::AdjustCountForDeadContributor ( int  iteration  ) 

Definition at line 253 of file MetaBalancer.C.

References adaptive_struct, ContributeStats(), get_finished_iteration(), LBDatabase::getLBDB(), index, MetaBalancer::AdaptiveLBStructure::lb_iteration_no, lbdatabase, LBDB::ObjDataCount(), and total_count_vec.

Referenced by CkMigratable::~CkMigratable().

Here is the call graph for this function:

Here is the caller graph for this function:

void MetaBalancer::AdjustCountForNewContributor ( int  iteration  ) 

Definition at line 238 of file MetaBalancer.C.

References get_finished_iteration(), index, and total_count_vec.

Referenced by CkMigratable::commonInit().

Here is the call graph for this function:

Here is the caller graph for this function:

bool MetaBalancer::AddLoad ( int  iteration,
double  load 
)

void MetaBalancer::SetCharePupSize ( size_t  psize  ) 

Definition at line 276 of file MetaBalancer.C.

References chare_pup_size.

Referenced by CkMigratable::AtSync().

Here is the caller graph for this function:

void MetaBalancer::ReceiveMinStats ( double *  load,
int  n 
)

Definition at line 411 of file MetaBalancer.C.

References _lb_args, adaptive_lbdb, adaptive_struct, CkLBArgs::alpha(), alpha_beta_cost_to_load, MetaBalancer::AdaptiveData::avg_load, MetaBalancer::AdaptiveData::avg_utilization, CkLBArgs::beta(), chare_pup_size, current_balancer, data, MetaBalancer::AdaptiveLBStructure::doCommStrategy, MetaBalancer::AdaptiveLBStructure::final_lb_period, generatePlan(), getLineEq(), GetPrevLBData(), MetaBalancer::AdaptiveMetaBalancer::history_data, IDLE_TIME, MetaBalancer::AdaptiveLBStructure::in_progress, MetaBalancer::AdaptiveLBStructure::info_first_iter, int, ITER_NO, MetaBalancer::AdaptiveData::iteration, MetaBalancer::AdaptiveLBStructure::lb_calculated_period, MetaBalancer::AdaptiveMetaBalancer::lb_iter_no, MetaBalancer::AdaptiveLBStructure::lb_msg_send_no, lbdb_no_obj_callback, LOAD_KURTOSIS, LOAD_SKEWNESS, LOAD_STDEV2, max(), MetaBalancer::AdaptiveLBInfo::max_avg_ratio, MAX_COMM_NEIGHBORS, MAX_ITER_TIME, MetaBalancer::AdaptiveData::max_load, MAX_LOAD, MAX_LOAD_W_BG, MAX_OBJ_LOAD, MAX_UTIL, CkLBArgs::metaLbModelDir(), min(), MIN_BG, MIN_LOAD, MIN_OBJ_LOAD, MetaBalancer::AdaptiveData::min_utilization, NUM_PROCS, OUTSIDE_PE_KBYTES, pe_ld_kurtosis, pe_ld_skewness, rFmodel, SUM_COMM_NEIGHBORS, SUM_HOP_KBYTES, SUM_HOPS, SUM_OBJ_COUNT, SUM_OBJ_LOAD, MetaBalancer::AdaptiveLBStructure::tentative_max_iter_no, TOTAL_KBYTES, TOTAL_KMSGS, TOTAL_LOAD, TOTAL_LOAD_W_BG, TOTAL_OVERLOADED_PES, total_ovld_pes, TriggerSoon(), UTILIZATION, and WITHIN_PE_KBYTES.

Referenced by ContributeStats(), and TriggerAdaptiveReduction().

Here is the call graph for this function:

Here is the caller graph for this function:

void MetaBalancer::TriggerSoon ( int  iteration_no,
double  imbalance_ratio,
double  tolerate_imb 
)

void MetaBalancer::LoadBalanceDecision ( int  req_no,
int  period 
)

void MetaBalancer::LoadBalanceDecisionFinal ( int  req_no,
int  period 
)

void MetaBalancer::MetaLBCallLBOnChares (  ) 

Definition at line 911 of file MetaBalancer.C.

References lbdatabase, and LBDatabase::MetaLBCallLBOnChares().

Here is the call graph for this function:

void MetaBalancer::MetaLBSetLBOnChares ( int  switchFrom,
int  switchTo 
)

Definition at line 915 of file MetaBalancer.C.

References lbdatabase, and LBDatabase::switchLoadbalancer().

Here is the call graph for this function:

void MetaBalancer::ReceiveIterationNo ( int  local_iter_no  ) 

void MetaBalancer::periodicCall ( void *  ad  )  [static]

Definition at line 970 of file MetaBalancer.C.

References _nobj_timer, CcdCallFnAfterOnPE(), checkForNoObj(), Converse::CkMyPe(), and PUP::s.

Referenced by init().

Here is the call graph for this function:

Here is the caller graph for this function:

void MetaBalancer::checkForNoObj ( void *  ad  )  [static]

Definition at line 975 of file MetaBalancer.C.

References HandleAdaptiveNoObj(), and PUP::s.

Referenced by periodicCall().

Here is the call graph for this function:

Here is the caller graph for this function:

void MetaBalancer::HandleAdaptiveNoObj (  ) 

void MetaBalancer::RegisterNoObjCallback ( int  index  ) 

void MetaBalancer::TriggerAdaptiveReduction (  ) 

void MetaBalancer::PreviousAvgLoad ( double  avg  ) 

Definition at line 1139 of file MetaBalancer.C.

References prev_avg_load.

bool MetaBalancer::generatePlan ( int period,
double &  ratio_at_t 
)

bool MetaBalancer::getLineEq ( double  new_load_percent,
double &  aslope,
double &  ac,
double &  mslope,
double &  mc 
)

bool MetaBalancer::getPeriodForLinear ( double  a,
double  b,
double  c,
int period 
)

Definition at line 812 of file MetaBalancer.C.

References int, PUP::t, and x.

Referenced by getPeriodForStrategy().

Here is the caller graph for this function:

bool MetaBalancer::getPeriodForStrategy ( double  new_load,
double  overhead_percent,
int period,
double &  ratio_at_t 
)

Definition at line 771 of file MetaBalancer.C.

References PUP::a, adaptive_struct, PUP::b, c, getLineEq(), getPeriodForLinear(), int, MetaBalancer::AdaptiveLBStructure::lb_migration_cost, and MetaBalancer::AdaptiveLBStructure::lb_strategy_cost.

Referenced by generatePlan().

Here is the call graph for this function:

Here is the caller graph for this function:

int MetaBalancer::getPredictedLBPeriod ( bool is_tentative  ) 

Definition at line 946 of file MetaBalancer.C.

References adaptive_struct, MetaBalancer::AdaptiveLBStructure::final_lb_period, and MetaBalancer::AdaptiveLBStructure::tentative_period.

Referenced by CkMigratable::recvLBPeriod().

Here is the caller graph for this function:

bool MetaBalancer::isStrategyComm (  ) 

void MetaBalancer::UpdateAfterLBData ( int  is_lb_refine,
double  lb_max,
double  lb_avg,
double  local_comm,
double  remote_comm 
)

void MetaBalancer::UpdateAfterLBData ( double  max_load,
double  max_cpu,
double  avg_load 
)

void MetaBalancer::UpdateAfterLBComm ( double  alpha_beta_cost  ) 

Definition at line 1085 of file MetaBalancer.C.

References alpha_beta_cost_to_load.

void MetaBalancer::GetPrevLBData ( int lb_type,
double &  lb_max_avg_ratio,
double &  local_remote_comm_ratio 
)

Definition at line 1091 of file MetaBalancer.C.

References adaptive_struct, GetLBDataForLB(), MetaBalancer::AdaptiveLBStructure::info_first_iter, MetaBalancer::AdaptiveLBStructure::last_lb_type, and MetaBalancer::AdaptiveLBInfo::max_avg_ratio.

Referenced by generatePlan(), ReceiveMinStats(), and AdaptiveLB::work().

Here is the call graph for this function:

Here is the caller graph for this function:

void MetaBalancer::GetLBDataForLB ( int  lb_type,
double &  lb_max_avg_ratio,
double &  local_remote_comm_ratio 
)

void MetaBalancer::SetMigrationCost ( double  lb_migration_cost  ) 

Definition at line 1045 of file MetaBalancer.C.

References adaptive_struct, and MetaBalancer::AdaptiveLBStructure::lb_migration_cost.

Referenced by LBDatabase::SetMigrationCost().

Here is the caller graph for this function:

void MetaBalancer::SetStrategyCost ( double  lb_strategy_cost  ) 

Definition at line 1049 of file MetaBalancer.C.

References adaptive_struct, and MetaBalancer::AdaptiveLBStructure::lb_strategy_cost.

Referenced by LBDatabase::SetStrategyCost().

Here is the caller graph for this function:


Field Documentation

Definition at line 97 of file MetaBalancer.h.

Referenced by init(), LoadBalanceDecision(), and pup().

std::vector<double> MetaBalancer::total_load_vec [private]

Definition at line 157 of file MetaBalancer.h.

Referenced by AddLoad(), ContributeStats(), and init().

std::vector<int> MetaBalancer::total_count_vec [private]

std::vector<double> MetaBalancer::max_load_vec [private]

Definition at line 160 of file MetaBalancer.h.

Referenced by AddLoad(), ContributeStats(), and init().

std::vector<double> MetaBalancer::min_load_vec [private]

Definition at line 161 of file MetaBalancer.h.

Referenced by AddLoad(), ContributeStats(), and init().

std::vector<int> MetaBalancer::lbdb_no_obj_callback [private]

Definition at line 162 of file MetaBalancer.h.

Referenced by ReceiveMinStats(), RegisterNoObjCallback(), and ResumeClients().

double MetaBalancer::prev_idle [private]

Definition at line 164 of file MetaBalancer.h.

Referenced by ContributeStats(), init(), pup(), and ResumeClients().

Definition at line 165 of file MetaBalancer.h.

Referenced by init(), pup(), ReceiveMinStats(), and UpdateAfterLBComm().

Definition at line 166 of file MetaBalancer.h.

Referenced by init(), and pup().

Definition at line 167 of file MetaBalancer.h.

Referenced by init(), pup(), and ResumeClients().

Definition at line 167 of file MetaBalancer.h.

Referenced by init(), pup(), and ResumeClients().

Definition at line 168 of file MetaBalancer.h.

Referenced by init(), pup(), and ResumeClients().

Definition at line 168 of file MetaBalancer.h.

Referenced by init(), pup(), and ResumeClients().

Definition at line 169 of file MetaBalancer.h.

Referenced by init(), pup(), and ResumeClients().

Definition at line 169 of file MetaBalancer.h.

Referenced by init(), pup(), and ResumeClients().

Definition at line 170 of file MetaBalancer.h.

Definition at line 171 of file MetaBalancer.h.

double MetaBalancer::prev_avg_load [private]

Definition at line 172 of file MetaBalancer.h.

Referenced by ContributeStats(), init(), PreviousAvgLoad(), and pup().

Definition at line 173 of file MetaBalancer.h.

Referenced by init(), pup(), ReceiveMinStats(), and SetCharePupSize().

double MetaBalancer::pe_ld_kurtosis [private]

Definition at line 174 of file MetaBalancer.h.

Referenced by ReceiveMinStats().

double MetaBalancer::pe_ld_skewness [private]

Definition at line 175 of file MetaBalancer.h.

Referenced by ReceiveMinStats().

Definition at line 176 of file MetaBalancer.h.

Referenced by ReceiveMinStats().

Definition at line 177 of file MetaBalancer.h.

Referenced by init(), and ReceiveMinStats().

Definition at line 178 of file MetaBalancer.h.

Referenced by init(), ReceiveMinStats(), and ~MetaBalancer().

Definition at line 238 of file MetaBalancer.h.

Referenced by init(), pup(), RegisterNoObjCallback(), ResetAdaptive(), and ResumeClients().


The documentation for this class was generated from the following files:

Generated on Mon Sep 21 08:27:39 2020 for Charm++ by  doxygen 1.5.5