4 XBT_LOG_EXTERNAL_DEFAULT_CATEGORY(loba);
6 #include "loba_fairstrategy.h"
8 void loba_fairstrategy::load_balance()
10 const double delta = 0.001;
12 std::sort(pneigh.begin(), pneigh.end(), pneigh_load_greater());
14 print_loads_p(false, xbt_log_priority_debug);
20 for (unsigned i = 0 ; i < pneigh.size() ; ++i) {
21 if (pneigh[i]->get_load() <= get_load() - 2 * delta) {
23 send(pneigh[i], delta);
24 XBT_DEBUG("sent to %s", pneigh[i]->get_name());