A
lgorithmique
N
umérique
D
istribuée
Public GIT Repository
projects
/
simgrid.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
[mc] Fix context registration which was disabled by a bug
[simgrid.git]
/
examples
/
simdag
/
sd_comm_throttling.c
diff --git
a/examples/simdag/sd_comm_throttling.c
b/examples/simdag/sd_comm_throttling.c
index
e16158c
..
8bbcf95
100644
(file)
--- a/
examples/simdag/sd_comm_throttling.c
+++ b/
examples/simdag/sd_comm_throttling.c
@@
-17,7
+17,7
@@
int main(int argc, char **argv)
{
unsigned int ctr;
const char *platform_file;
- const
SD_workstation
_t *workstations;
+ const
sg_host
_t *workstations;
SD_task_t task, taskA, taskB, taskC, taskD, taskE;
xbt_dynar_t changed_tasks;
@@
-26,17
+26,14
@@
int main(int argc, char **argv)
/* xbt_log_control_set("sd.thres=debug"); */
- if (argc < 2) {
- XBT_INFO("Usage: %s platform_file", argv[0]);
- XBT_INFO("example: %s sd_platform.xml", argv[0]);
- exit(1);
- }
+ xbt_assert(argc > 1, "Usage: %s platform_file\n"
+ "\nExample: %s two_clusters.xml", argv[0], argv[0]);
/* creation of the environment */
platform_file = argv[1];
SD_create_environment(platform_file);
- workstations =
SD_workstation_ge
t_list();
+ workstations =
sg_hos
t_list();
/* creation of some typed tasks and their dependencies */
/* chain of five tasks, three compute tasks with two data transfers */
@@
-79,9
+76,7
@@
int main(int argc, char **argv)
*/
if (SD_task_get_state(taskC) == SD_DONE && SD_task_get_state(taskD) < SD_RUNNING)
SD_task_set_rate(taskD, 6.25);
- xbt_dynar_free_container(&changed_tasks);
}
- xbt_dynar_free_container(&changed_tasks);
XBT_DEBUG("Destroying tasks...");