"Latency factors for smpi.",
xbt_cfgelm_string, 1, 1, NULL, NULL);
xbt_cfg_setdefault_string(_sg_cfg_set, "smpi/lat_factor", "65472:11.6436;15424:3.48845;9376:2.59299;5776:2.18796;3484:1.88101;1426:1.61075;732:1.9503;257:1.95341;0:2.01467");
-
+
+ xbt_cfg_register(&_sg_cfg_set, "smpi/IB_penalty_factors",
+ "Correction factor to communications using Infiniband model with contention (default value based on Stampede cluster profiling)",
+ xbt_cfgelm_string, 1, 1, NULL, NULL);
+ xbt_cfg_setdefault_string(_sg_cfg_set, "smpi/IB_penalty_factors", "0.965;0.925;1.35");
+
xbt_cfg_register(&_sg_cfg_set, "smpi/os",
"Small messages timings (MPI_Send minimum time for small messages)",
xbt_cfgelm_string, 1, 1, NULL, NULL);
XBT_LOG_EXTERNAL_DEFAULT_CATEGORY(surf_network);
-double Bs=0.925;
-double Be=0.965;
-double ys=1.35;
-
-
static void IB_create_host_callback(sg_platf_host_cbarg_t t){
static int id=0;
sg_platf_host_add_cb(IB_create_host_callback);
xbt_cfg_setdefault_double(_sg_cfg_set, "network/weight_S", 8775);
+
}
NetworkIBModel::NetworkIBModel()
: NetworkSmpiModel() {
m_haveGap=false;
active_nodes=NULL;
+
+ const char* IB_factors_string=sg_cfg_get_string("smpi/IB_penalty_factors");
+ xbt_dynar_t radical_elements = xbt_str_split(IB_factors_string, ";");
+
+ if(xbt_dynar_length(radical_elements)!=3)
+ surf_parse_error("smpi/IB_penalty_factors should be provided and contain 3 elements, semi-colon separated : for example 0.965;0.925;1.35");
+
+ Be = atof(xbt_dynar_get_as(radical_elements, 0, char *));
+ Bs = atof(xbt_dynar_get_as(radical_elements, 1, char *));
+ ys = atof(xbt_dynar_get_as(radical_elements, 2, char *));
}
NetworkIBModel::~NetworkIBModel()