result = MAX(sg_host_get_available_at(workstation),
last_data_available) +
- sg_host_computation_time(workstation,
- SD_task_get_amount(task));
+ SD_task_get_amount(task)/sg_host_speed(workstation);
} else {
xbt_dynar_free_container(&parents);
result = sg_host_get_available_at(workstation) +
- sg_host_computation_time(workstation,
- SD_task_get_amount(task));
+ SD_task_get_amount(task)/sg_host_speed(workstation);
}
return result;
}
communication_amount12 = 2000000;
communication_amount21 = 3000000;
XBT_INFO("Computation time for %f flops on %s: %f", computation_amount1,
- name1, sg_host_computation_time(w1,
- computation_amount1));
+ name1, computation_amount1/sg_host_speed(w1));
XBT_INFO("Computation time for %f flops on %s: %f", computation_amount2,
- name2, sg_host_computation_time(w2,
- computation_amount2));
+ name2, computation_amount2/sg_host_speed(w2));
XBT_INFO("Route between %s and %s:", name1, name2);
route = SD_route_get_list(w1, w2);
* @see sg_host_t
* @{
*/
-XBT_PUBLIC(double) sg_host_computation_time(sg_host_t host,
- double flops_amount);
-
XBT_PUBLIC(const SD_link_t *) SD_route_get_list(sg_host_t src,
sg_host_t dst);
XBT_PUBLIC(int) SD_route_get_size(sg_host_t src, sg_host_t dst);
xbt_free(s);
}
-double sg_host_computation_time(sg_host_t host, double flops_amount)
-{
- xbt_assert(flops_amount >= 0,
- "flops_amount must be greater than or equal to zero");
- return flops_amount / sg_host_speed(host);
-}
-
/**
* \brief Returns the route between two workstations
*