diff --git a/src/vt/vrt/collection/balance/baselb/baselb.cc b/src/vt/vrt/collection/balance/baselb/baselb.cc index 08a89716a1..2b4ce5c67f 100644 --- a/src/vt/vrt/collection/balance/baselb/baselb.cc +++ b/src/vt/vrt/collection/balance/baselb/baselb.cc @@ -84,12 +84,6 @@ std::shared_ptr BaseLB::startLB( return normalizeReassignments(); } -/*static*/ -BaseLB::LoadType BaseLB::loadMilli(LoadType const& load) { - // Convert `load` in seconds to milliseconds, typically for binning purposes - return load * 1000; -} - void BaseLB::importProcessorData( StatisticMapType const& in_stats, ElementCommType const& comm_in ) { diff --git a/src/vt/vrt/collection/balance/baselb/baselb.h b/src/vt/vrt/collection/balance/baselb/baselb.h index 77cb3e9f21..cabf7defa4 100644 --- a/src/vt/vrt/collection/balance/baselb/baselb.h +++ b/src/vt/vrt/collection/balance/baselb/baselb.h @@ -118,8 +118,6 @@ struct BaseLB { StatisticMapType const& in_stats, ElementCommType const& cm ); - static LoadType loadMilli(LoadType const& load); - void notifyCurrentHostNodeOfObjectsDeparting( TransferMsg* msg ); diff --git a/src/vt/vrt/collection/balance/baselb/load_sampler.cc b/src/vt/vrt/collection/balance/baselb/load_sampler.cc index cda4df4060..10b3b989f1 100644 --- a/src/vt/vrt/collection/balance/baselb/load_sampler.cc +++ b/src/vt/vrt/collection/balance/baselb/load_sampler.cc @@ -52,7 +52,7 @@ void LoadSamplerBaseLB::buildHistogram() { TimeType load = load_model_->getModeledLoad( obj, {balance::PhaseOffset::NEXT_PHASE, balance::PhaseOffset::WHOLE_PHASE} ); - auto const& load_milli = loadMilli(load.seconds()); + auto const& load_milli = load.milliseconds(); auto const& bin = histogramSample(load_milli); if (obj.isMigratable()) { obj_sample[bin].push_back(obj); diff --git a/src/vt/vrt/collection/balance/greedylb/greedylb.cc b/src/vt/vrt/collection/balance/greedylb/greedylb.cc index d903af1283..92353c8bed 100644 --- a/src/vt/vrt/collection/balance/greedylb/greedylb.cc +++ b/src/vt/vrt/collection/balance/greedylb/greedylb.cc @@ -144,7 +144,7 @@ void GreedyLB::inputParams(balance::ConfigEntry* config) { } void GreedyLB::runLB(TimeType total_load) { - this_load = loadMilli(total_load.seconds()); + this_load = total_load.milliseconds(); buildHistogram(); loadStats(); } @@ -413,9 +413,9 @@ void GreedyLB::loadOverBin(ObjBinType bin, ObjBinListType& bin_list) { load_over[bin].push_back(obj_id); bin_list.pop_back(); - auto const& obj_time_milli = loadMilli(load_model_->getModeledLoad( + auto const& obj_time_milli = load_model_->getModeledLoad( obj_id, {balance::PhaseOffset::NEXT_PHASE, balance::PhaseOffset::WHOLE_PHASE} - ).seconds()); + ).milliseconds(); this_load -= obj_time_milli; diff --git a/src/vt/vrt/collection/balance/hierarchicallb/hierlb.cc b/src/vt/vrt/collection/balance/hierarchicallb/hierlb.cc index 4f84cc5528..5920bc725d 100644 --- a/src/vt/vrt/collection/balance/hierarchicallb/hierlb.cc +++ b/src/vt/vrt/collection/balance/hierarchicallb/hierlb.cc @@ -312,9 +312,9 @@ void HierarchicalLB::loadOverBin(ObjBinType bin, ObjBinListType& bin_list) { load_over[bin].push_back(obj_id); bin_list.pop_back(); - auto const& obj_time_milli = loadMilli(load_model_->getModeledLoad(obj_id, + auto const& obj_time_milli = load_model_->getModeledLoad(obj_id, {balance::PhaseOffset::NEXT_PHASE, balance::PhaseOffset::WHOLE_PHASE} - ).seconds()); + ).milliseconds(); this_load -= obj_time_milli; diff --git a/src/vt/vrt/collection/balance/zoltanlb/zoltanlb.cc b/src/vt/vrt/collection/balance/zoltanlb/zoltanlb.cc index 94612a8149..a0943b6873 100644 --- a/src/vt/vrt/collection/balance/zoltanlb/zoltanlb.cc +++ b/src/vt/vrt/collection/balance/zoltanlb/zoltanlb.cc @@ -131,7 +131,7 @@ void ZoltanLB::inputParams(balance::ConfigEntry* config) { void ZoltanLB::runLB(TimeType total_load) { auto const& this_node = theContext()->getNode(); - this_load = loadMilli(total_load); + this_load = total_load.milliseconds()); if (this_node == 0) { vt_debug_print(terse, lb, "ZoltanLB: runLB: edges={}\n", do_edges_); @@ -487,7 +487,7 @@ std::unique_ptr ZoltanLB::makeGraph() { obj, {balance::PhaseOffset::NEXT_PHASE, balance::PhaseOffset::WHOLE_PHASE} ); - auto time = static_cast(loadMilli(load)); + auto time = static_cast(load.milliseconds()); graph->vertex_weight[idx++] = time; } }