- /* Create the configuration support */
- if (_sg_cfg_init_status == 0) { /* Only create stuff if not already inited */
-
- /* Plugins configuration */
- describe_model(description, surf_plugin_description,
- "plugin", "The plugins");
- xbt_cfg_register(&_sg_cfg_set, "plugin", description,
- xbt_cfgelm_string, 0, 1, &_sg_cfg_cb__plugin);
-
- describe_model(description, surf_cpu_model_description, "model", "The model to use for the CPU");
- xbt_cfg_register_string(&_sg_cfg_set, "cpu/model", description, "Cas01", &_sg_cfg_cb__cpu_model);
-
- describe_model(description, surf_optimization_mode_description, "optimization mode", "The optimization modes to use for the CPU");
- xbt_cfg_register_string(&_sg_cfg_set, "cpu/optim", description, "Lazy", &_sg_cfg_cb__optimization_mode);
-
- describe_model(description, surf_storage_model_description, "model", "The model to use for the storage");
- xbt_cfg_register_string(&_sg_cfg_set, "storage/model", description, "default", &_sg_cfg_cb__storage_mode);
-
- describe_model(description, surf_network_model_description, "model", "The model to use for the network");
- xbt_cfg_register_string(&_sg_cfg_set, "network/model", description, "LV08", &_sg_cfg_cb__network_model);
-
- describe_model(description, surf_optimization_mode_description, "optimization mode", "The optimization modes to use for the network");
- xbt_cfg_register_string(&_sg_cfg_set, "network/optim", description, "Lazy", &_sg_cfg_cb__optimization_mode);
-
- describe_model(description, surf_host_model_description, "model", "The model to use for the host");
- xbt_cfg_register_string(&_sg_cfg_set, "host/model", description, "default", &_sg_cfg_cb__host_model);
-
- describe_model(description, surf_vm_model_description, "model", "The model to use for the vm");
- xbt_cfg_register_string(&_sg_cfg_set, "vm/model", description, "default", &_sg_cfg_cb__vm_model);
-
- xbt_cfg_register_double(&_sg_cfg_set, "network/TCP_gamma",
- "Size of the biggest TCP window (cat /proc/sys/net/ipv4/tcp_[rw]mem for recv/send window; Use the last given value, which is the max window size)",
- 4194304.0, _sg_cfg_cb__tcp_gamma);
-
- xbt_cfg_register_double(&_sg_cfg_set, "surf/precision", "Numerical precision used when updating simulation times (in seconds)",
- 0.00001, _sg_cfg_cb__surf_precision);
-
- xbt_cfg_register_double(&_sg_cfg_set, "maxmin/precision",
- "Numerical precision used when computing resource sharing (in ops/sec or bytes/sec)",
- 0.00001, _sg_cfg_cb__maxmin_precision);
-
- /* The parameters of network models */
-
- xbt_cfg_register_double(&_sg_cfg_set, "network/sender_gap", "Minimum gap between two overlapping sends",
- NAN, _sg_cfg_cb__sender_gap); /* real default for "network/sender_gap" is set in network_smpi.cpp */
- xbt_cfg_register_double(&_sg_cfg_set, "network/latency_factor",
- "Correction factor to apply to the provided latency (default value set by network model)",
- 1.0, _sg_cfg_cb__latency_factor);
- xbt_cfg_register_double(&_sg_cfg_set, "network/bandwidth_factor",
- "Correction factor to apply to the provided bandwidth (default value set by network model)",
- 1.0, _sg_cfg_cb__bandwidth_factor);
- xbt_cfg_register_double(&_sg_cfg_set, "network/weight_S",
- "Correction factor to apply to the weight of competing streams (default value set by network model)",
- NAN, _sg_cfg_cb__weight_S); /* real default for "network/weight_S" is set in network_*.cpp */
-
- /* Inclusion path */
- xbt_cfg_register(&_sg_cfg_set, "path",
- "Lookup path for inclusions in platform and deployment XML files",
- xbt_cfgelm_string, 1, 0, _sg_cfg_cb__surf_path);
-
- xbt_cfg_register_boolean(&_sg_cfg_set, "cpu/maxmin_selective_update",
- "Update the constraint set propagating recursively to others constraints (off by default when optim is set to lazy)",
- "no", NULL);
- xbt_cfg_register_boolean(&_sg_cfg_set, "network/maxmin_selective_update",
- "Update the constraint set propagating recursively to others constraints (off by default when optim is set to lazy)",
- "no", NULL);
- /* Replay (this part is enabled even if MC it disabled) */
- xbt_cfg_register(&_sg_cfg_set, "model-check/replay",
- "Enable replay mode with the given path", xbt_cfgelm_string, 0, 1, _sg_cfg_cb_model_check_replay);
-
-#if HAVE_MC
- /* do model-checking-record */
- xbt_cfg_register_boolean(&_sg_cfg_set, "model-check/record", "Record the model-checking paths",
- "no", _sg_cfg_cb_model_check_record);
-
- /* do stateful model-checking */
- xbt_cfg_register_int(&_sg_cfg_set, "model-check/checkpoint",
- "Specify the amount of steps between checkpoints during stateful model-checking (default: 0 => stateless verification). "
- "If value=1, one checkpoint is saved for each step => faster verification, but huge memory consumption; higher values are good compromises between speed and memory consumption.",
- 0, _mc_cfg_cb_checkpoint);
-
- /* do stateful model-checking */
- xbt_cfg_register_boolean(&_sg_cfg_set, "model-check/sparse_checkpoint", "Use sparse per-page snapshots.",
- "no", _mc_cfg_cb_sparse_checkpoint);
-
- /* do stateful model-checking */
- xbt_cfg_register_boolean(&_sg_cfg_set, "model-check/soft-dirty", "Use sparse per-page snapshots.",
- "no", _mc_cfg_cb_soft_dirty);
-
- xbt_cfg_register(&_sg_cfg_set, "model-check/ksm",
- "Kernel same-page merging",
- xbt_cfgelm_boolean, 1, 1, _mc_cfg_cb_ksm);
- xbt_cfg_setdefault_boolean(_sg_cfg_set, "model-check/ksm", "no");
-
- /* do liveness model-checking */
- xbt_cfg_register(&_sg_cfg_set, "model-check/property",
- "Specify the name of the file containing the property. It must be the result of the ltl2ba program.",
- xbt_cfgelm_string, 1, 1, _mc_cfg_cb_property);
- xbt_cfg_setdefault_string(_sg_cfg_set, "model-check/property", "");
-
- /* do communications determinism model-checking */
- xbt_cfg_register_boolean(&_sg_cfg_set, "model-check/communications_determinism",
- "Enable/disable the detection of determinism in the communications schemes", "no", _mc_cfg_cb_comms_determinism);
-
- /* do send determinism model-checking */
- xbt_cfg_register_boolean(&_sg_cfg_set, "model-check/send_determinism",
- "Enable/disable the detection of send-determinism in the communications schemes", "no", _mc_cfg_cb_send_determinism);
-
- /* Specify the kind of model-checking reduction */
- xbt_cfg_register_string(&_sg_cfg_set, "model-check/reduction", "Specify the kind of exploration reduction (either none or DPOR)",
- "dpor", _mc_cfg_cb_reduce);
-
- /* Enable/disable timeout for wait requests with model-checking */
- xbt_cfg_register_boolean(&_sg_cfg_set, "model-check/timeout", "Enable/Disable timeout for wait requests", "no",
- _mc_cfg_cb_timeout);
-
- /* Enable/disable global hash computation with model-checking */
- xbt_cfg_register_boolean(&_sg_cfg_set, "model-check/hash", "Enable/Disable state hash for state comparison (experimental)", "no",
- _mc_cfg_cb_hash);
-
- /* Set max depth exploration */
- xbt_cfg_register_boolean(&_sg_cfg_set, "model-check/snapshot_fds", "Whether file descriptors must be snapshoted (currently unusable)", "no",
- _mc_cfg_cb_snapshot_fds);
-
- /* Set max depth exploration */
- xbt_cfg_register_int(&_sg_cfg_set, "model-check/max_depth", "Specify the max depth of exploration (default: 1000)", 1000,
- _mc_cfg_cb_max_depth);
-
- /* Set number of visited state stored for state comparison reduction*/
- xbt_cfg_register_int(&_sg_cfg_set, "model-check/visited",
- "Specify the number of visited state stored for state comparison reduction. If value=5, the last 5 visited states are stored",
- 0, _mc_cfg_cb_visited);
-
- /* Set file name for dot output of graph state */
- xbt_cfg_register_string(&_sg_cfg_set, "model-check/dot_output",
- "Specify the name of dot file corresponding to graph state",
- "", _mc_cfg_cb_dot_output);
-
- /* Enable/disable non progressive cycles detection with model-checking */
- xbt_cfg_register_boolean(&_sg_cfg_set, "model-check/termination",
- "Enable/Disable non progressive cycle detection",
- "no", _mc_cfg_cb_termination);
-#endif