- action->variable = lmm_variable_new(maxmin_system, action, 1.0, -1.0,
- route_size);
- for(i=0; i<route_size; i++)
- lmm_expand(maxmin_system, route[i]->constraint, action->variable,
- 1.0);
+ action->latency = 0.0;
+ for (i = 0; i < route_size; i++)
+ action->latency += route[i]->lat_current;
+ action->lat_current = action->latency;
+
+ if(action->latency>0)
+ action->variable = lmm_variable_new(maxmin_system, action, 0.0, -1.0,
+ route_size);
+ else
+ action->variable = lmm_variable_new(maxmin_system, action, 1.0, -1.0,
+ route_size);
+
+ lmm_update_variable_bound(maxmin_system, action->variable,
+ SG_TCP_CTE_GAMMA / action->lat_current);
+
+ for (i = 0; i < route_size; i++)
+ lmm_expand(maxmin_system, route[i]->constraint, action->variable, 1.0);