X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/bcee12262f157b5a931b52ff5f32855888c6202d..472cf0c9125f4826985bb0a400086d83c3a9ebaa:/examples/simdag/metaxml/sd_meta.c diff --git a/examples/simdag/metaxml/sd_meta.c b/examples/simdag/metaxml/sd_meta.c index 6122aca9be..17947d72dc 100644 --- a/examples/simdag/metaxml/sd_meta.c +++ b/examples/simdag/metaxml/sd_meta.c @@ -1,6 +1,13 @@ -/* - See examples/platforms/metaxml.xml and examples/platforms/metaxml_platform.xml files for examples on how to use the cluster, foreach, set, route:multi, trace and trace:connect tags +/* Copyright (c) 2007-2012. The SimGrid Team. + * All rights reserved. */ + +/* This program is free software; you can redistribute it and/or modify it + * under the terms of the license (GNU LGPL) which comes with this package. */ + +/* See examples/platforms/metaxml.xml and examples/platforms/metaxml_platform.xml + for examples on how to use the cluster, foreach, set, route:multi, trace and trace:connect tags */ + #include #include #include "simdag/simdag.h" @@ -8,20 +15,20 @@ #include "xbt/log.h" #include "xbt/dynar.h" #include "xbt/dict.h" -#include "xbt/time.h" XBT_LOG_NEW_DEFAULT_CATEGORY(sd_test, - "Logging specific to this SimDag example"); + "Logging specific to this SimDag example"); -int main(int argc, char **argv) { +int main(int argc, char **argv) +{ - const char * platform_file; - const SD_workstation_t *workstations; + const char *platform_file; + const SD_workstation_t *workstations; int ws_nr; - SD_workstation_t w1 = NULL; + SD_workstation_t w1 = NULL; SD_workstation_t w2 = NULL; const char *name1, *name2; - int i,j,k; + int i, j, k; /* initialisation of SD */ SD_init(&argc, argv); @@ -29,8 +36,8 @@ int main(int argc, char **argv) { /* xbt_log_control_set("sd.thres=debug"); */ if (argc < 2) { - INFO1("Usage: %s platform_file", argv[0]); - INFO1("example: %s sd_platform.xml", argv[0]); + XBT_INFO("Usage: %s platform_file", argv[0]); + XBT_INFO("example: %s sd_platform.xml", argv[0]); exit(1); } @@ -42,23 +49,25 @@ int main(int argc, char **argv) { workstations = SD_workstation_get_list(); ws_nr = SD_workstation_get_number(); - + /* Show routes between all workstation */ - - for (i=0; i