Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Kill old $Id$ command dating from CVS
[simgrid.git] / src / msg / msg_config.c
1 /* Copyright (c) 2002-2007 Arnaud Legrand.                                  */
2 /* Copyright (c) 2007 Bruno Donassolo.                                      */
3 /* All rights reserved.                                                     */
4
5 /* This program is free software; you can redistribute it and/or modify it
6  * under the terms of the license (GNU LGPL) which comes with this package. */
7
8 #include "msg/private.h"
9 #include "xbt/sysdep.h"
10 #include "xbt/log.h"
11 #include "simix/simix.h"
12
13 /** \brief set a configuration variable
14  *
15  * Currently existing configuation variable:
16  *   - workstation/model (string): Model of workstation to use.
17  *     Possible values (defaults to "KCCFLN05"):
18  *     - "CLM03": realistic TCP behavior + basic CPU model (see [CML03 at CCGrid03]) + support for parallel tasks
19  *     - "KCCFLN05": realistic TCP behavior + basic CPU model (see [CML03 at CCGrid03]) + failure handling + interference between communications and computations if precised in the platform file.
20  *     - "KCCFLN05": realistic TCP behavior + basic CPU model (see [CML03 at CCGrid03]) + failure handling + interference between communications and computations if precised in the platform file. Use maxmin for the network.
21  *     - "KCCFLN05_proportional": realistic TCP behavior + basic CPU model (see [CML03 at CCGrid03]) + failure handling + interference between communications and computations if precised in the platform file. Uses the proportional approahc as described in the Corine Touati's PhD Thesis.
22  *     - "KCCFLN05_Vegas": realistic TCP behavior + basic CPU model (see [CML03 at CCGrid03]) + failure handling + interference between communications and computations if precised in the platform file. Uses the fairness adapted to the TCP Vegas flow control.
23  *     - "KCCFLN05_Reno": realistic TCP behavior + basic CPU model (see [CML03 at CCGrid03]) + failure handling + interference between communications and computations if precised in the platform file. Uses the fairness adapted to the TCP Reno flow control.
24  *
25  * Example:
26  * MSG_config("workstation/model","KCCFLN05");
27  */
28 void MSG_config(const char *name, ...)
29 {
30   va_list pa;
31
32   if (!msg_global) {
33     fprintf(stderr,
34             "ERROR: Please call MSG_init() before using MSG_config()\n");
35     abort();
36   }
37   va_start(pa, name);
38   xbt_cfg_set_vargs(_surf_cfg_set, name, pa);
39   va_end(pa);
40   return;
41 }