+ network_maxmin_system = lmm_system_new(net_selective_update);
+
+ routing_model_create(sizeof(link_CM02_t),
+ net_create_resource("__loopback__",
+ 498000000, NULL, 0.000015, NULL,
+ SURF_RESOURCE_ON, NULL,
+ SURF_LINK_FATPIPE, NULL));
+
+ if (network_update_mechanism == UM_LAZY) {
+ net_action_heap = xbt_heap_new(8, NULL);
+ xbt_heap_set_update_callback(net_action_heap,
+ net_action_update_index_heap);
+ net_modified_set =
+ xbt_swag_new(xbt_swag_offset(comm, generic_lmm_action.action_list_hookup));
+ network_maxmin_system->keep_track = net_modified_set;
+ }
+}
+
+static void set_update_mechanism(void)
+{
+#ifdef HAVE_TRACING
+ TRACE_set_network_update_mechanism();
+#endif
+
+ char *optim = xbt_cfg_get_string(_surf_cfg_set, "network/optim");
+ int select =
+ xbt_cfg_get_int(_surf_cfg_set, "network/maxmin_selective_update");
+
+ if (!strcmp(optim, "Full")) {
+ network_update_mechanism = UM_FULL;
+ net_selective_update = select;
+ } else if (!strcmp(optim, "Lazy")) {
+ network_update_mechanism = UM_LAZY;
+ net_selective_update = 1;
+ xbt_assert((select == 1)
+ ||
+ (xbt_cfg_is_default_value
+ (_surf_cfg_set, "network/maxmin_selective_update")),
+ "Disabling selective update while using the lazy update mechanism is dumb!");
+ } else {
+ xbt_die("Unsupported optimization (%s) for this model", optim);
+ }
+}
+
+/************************************************************************/
+/* New model based on LV08 and experimental results of MPI ping-pongs */
+/************************************************************************/
+/* @Inproceedings{smpi_ipdps, */
+/* author={Pierre-Nicolas Clauss and Mark Stillwell and Stéphane Genaud and Frédéric Suter and Henri Casanova and Martin Quinson}, */
+/* title={Single Node On-Line Simulation of {MPI} Applications with SMPI}, */
+/* booktitle={25th IEEE International Parallel and Distributed Processing Symposium (IPDPS'11)}, */
+/* address={Anchorage (Alaska) USA}, */
+/* month=may, */
+/* year={2011} */
+/* } */
+void surf_network_model_init_SMPI(void)
+{
+
+ if (surf_network_model)
+ return;
+ set_update_mechanism();
+
+ surf_network_model_init_internal();
+ latency_factor_callback = &smpi_latency_factor;
+ bandwidth_factor_callback = &smpi_bandwidth_factor;
+ bandwidth_constraint_callback = &smpi_bandwidth_constraint;
+ gap_append = &smpi_gap_append;
+ gap_remove = &smpi_gap_remove;
+ net_define_callbacks();
+ xbt_dynar_push(model_list, &surf_network_model);
+ network_solve = lmm_solve;
+
+ xbt_cfg_setdefault_double(_surf_cfg_set, "network/sender_gap", 10e-6);
+ xbt_cfg_setdefault_double(_surf_cfg_set, "network/weight_S", 8775);
+}
+
+/************************************************************************/
+/* New model based on optimizations discussed during Pedro Velho's thesis*/
+/************************************************************************/
+/* @techreport{VELHO:2011:HAL-00646896:1, */
+/* url = {http://hal.inria.fr/hal-00646896/en/}, */
+/* title = {{Flow-level network models: have we reached the limits?}}, */
+/* author = {Velho, Pedro and Schnorr, Lucas and Casanova, Henri and Legrand, Arnaud}, */
+/* type = {Rapport de recherche}, */
+/* institution = {INRIA}, */
+/* number = {RR-7821}, */
+/* year = {2011}, */
+/* month = Nov, */
+/* pdf = {http://hal.inria.fr/hal-00646896/PDF/rr-validity.pdf}, */
+/* } */
+void surf_network_model_init_LegrandVelho(void)
+{
+ if (surf_network_model)
+ return;
+
+ set_update_mechanism();
+
+ surf_network_model_init_internal();
+ net_define_callbacks();
+ xbt_dynar_push(model_list, &surf_network_model);
+ network_solve = lmm_solve;
+
+ xbt_cfg_setdefault_double(_surf_cfg_set, "network/latency_factor",
+ 13.01);
+ xbt_cfg_setdefault_double(_surf_cfg_set, "network/bandwidth_factor",
+ 0.97);
+ xbt_cfg_setdefault_double(_surf_cfg_set, "network/weight_S", 20537);