X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/272ccad1b68b6d9c17069f3c934886925bb15b5d..2e6cdac131b649b1ccd7d8e8c5fe85c0dcf57904:/examples/simdag/sd_comm_throttling.c diff --git a/examples/simdag/sd_comm_throttling.c b/examples/simdag/sd_comm_throttling.c index aa81fe6a8c..4a354ae4e2 100644 --- a/examples/simdag/sd_comm_throttling.c +++ b/examples/simdag/sd_comm_throttling.c @@ -72,9 +72,14 @@ int main(int argc, char **argv) } /* let throttle the communication for taskD if its parent is SD_DONE */ + /* the bandwidth is 1.25e8, the data size is 1e7, and we want to throttle + * the bandwidth by a factor 2. the rate is then 1.25e8/(2*1e7)=6.25 + */ if (SD_task_get_state(taskC) == SD_DONE) - SD_task_set_rate(taskD, 0.5); + SD_task_set_rate(taskD, 6.25); + xbt_dynar_free_container(&changed_tasks); } + xbt_dynar_free_container(&changed_tasks); XBT_DEBUG("Destroying tasks...");