Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Fix lua platform script
[simgrid.git] / src / simgrid / sg_config.c
index e647b9d..ccf75d1 100644 (file)
@@ -18,7 +18,9 @@
 #include "instr/instr_interface.h"
 #include "simgrid/simix.h"
 #include "simgrid/sg_config.h"
-#include "mc/mc.h" 
+#include "smpi/smpi_interface.h"
+#include "mc/mc.h"
+#include "instr/instr.h"
 
 XBT_LOG_NEW_DEFAULT_SUBCATEGORY(surf_config, surf,
                                 "About the configuration of simgrid");
@@ -97,7 +99,6 @@ static void sg_config_cmd_line(int *argc, char **argv)
   }
 }
 
-
 /* callback of the workstation/model variable */
 static void _sg_cfg_cb__workstation_model(const char *name, int pos)
 {
@@ -455,17 +456,16 @@ void sg_config_init(int *argc, char **argv)
     xbt_cfg_register(&_sg_cfg_set, "maxmin/precision",
                      "Numerical precision used when updating simulation models (epsilon in double comparisons)",
                      xbt_cfgelm_double, NULL, 1, 1, _sg_cfg_cb__maxmin_precision, NULL);
-    xbt_cfg_setdefault_double(_sg_cfg_set, "maxmin/precision", 0.00001); // FIXME use setdefault everywhere here!
+    xbt_cfg_setdefault_double(_sg_cfg_set, "maxmin/precision", 0.00001); 
 
     /* The parameters of network models */
 
-    double_default_value = 0.0;
     xbt_cfg_register(&_sg_cfg_set, "network/sender_gap",
                      "Minimum gap between two overlapping sends",
-                     xbt_cfgelm_double, &double_default_value, 1, 1,
+                     xbt_cfgelm_double, NULL, 1, 1, /* default is set in network.c */
                      _sg_cfg_cb__sender_gap, NULL);
 
-    double_default_value = 1.0;
+    double_default_value = 1.0; // FIXME use setdefault everywhere here!
     xbt_cfg_register(&_sg_cfg_set, "network/latency_factor",
                      "Correction factor to apply to the provided latency (default value set by network model)",
                      xbt_cfgelm_double, &double_default_value, 1, 1,
@@ -475,10 +475,10 @@ void sg_config_init(int *argc, char **argv)
                      "Correction factor to apply to the provided bandwidth (default value set by network model)",
                      xbt_cfgelm_double, &double_default_value, 1, 1,
                      _sg_cfg_cb__bandwidth_factor, NULL);
-    double_default_value = 0.0;
+
     xbt_cfg_register(&_sg_cfg_set, "network/weight_S",
                      "Correction factor to apply to the weight of competing streams(default value set by network model)",
-                     xbt_cfgelm_double, &double_default_value, 1, 1,
+                     xbt_cfgelm_double, NULL, 1, 1, /* default is set in network.c */
                      _sg_cfg_cb__weight_S, NULL);
 
     /* Inclusion path */