- lmm_expand(ptask_maxmin_system,
- sg_host_surfcpu(host_list[i])->getConstraint(),
- action->getVariable(), flops_amount[i]);
-
- for (int i = 0; i < host_nb; i++) {
- for (int j = 0; j < host_nb; j++) {
- void *_link;
-
- xbt_dynar_t route=NULL;
- if (bytes_amount[i * host_nb + j] == 0.0)
- continue;
-
- routing_platf->getRouteAndLatency((*action->p_edgeList)[i], (*action->p_edgeList)[j],
- &route, NULL);
-
- xbt_dynar_foreach(route, cpt, _link) {
- LinkL07 *link = static_cast<LinkL07*>(_link);
- lmm_expand_add(ptask_maxmin_system, link->getConstraint(),
- action->getVariable(),
- bytes_amount[i * host_nb + j]);
+ lmm_expand(model->getMaxminSystem(),
+ host_list[i]->pimpl_cpu->getConstraint(),
+ this->getVariable(), flops_amount[i]);
+
+ if(bytes_amount != NULL) {
+ for (int i = 0; i < host_nb; i++) {
+ for (int j = 0; j < host_nb; j++) {
+ void *_link;
+
+ xbt_dynar_t route=NULL;
+ if (bytes_amount[i * host_nb + j] == 0.0)
+ continue;
+
+ routing_platf->getRouteAndLatency((*this->p_netcardList)[i], (*this->p_netcardList)[j],
+ &route, NULL);
+
+ xbt_dynar_foreach(route, cpt, _link) {
+ LinkL07 *link = static_cast<LinkL07*>(_link);
+ lmm_expand_add(model->getMaxminSystem(), link->getConstraint(),
+ this->getVariable(), bytes_amount[i * host_nb + j]);
+ }