#include "simgrid/sg_config.hpp"
#include "simgrid/instr.h"
+#include "simgrid/version.h"
#include "src/instr/instr_private.hpp"
#include "src/internal_config.h"
#include "src/kernel/lmm/maxmin.hpp"
find_model_description(surf_optimization_mode_description, value);
}
+static void _sg_cfg_cb__disk_model(const std::string& value)
+{
+ xbt_assert(_sg_cfg_init_status < 2, "Cannot change the model after the initialization");
+
+ if (value == "help") {
+ model_help("disk", surf_disk_model_description);
+ exit(0);
+ }
+
+ find_model_description(surf_disk_model_description, value);
+}
+
/* callback of the cpu/model variable */
-static void _sg_cfg_cb__storage_mode(const std::string& value)
+static void _sg_cfg_cb__storage_model(const std::string& value)
{
xbt_assert(_sg_cfg_init_status < 2, "Cannot change the model after the initialization");
declare_model_flag("cpu/model", "Cas01", &_sg_cfg_cb__cpu_model, surf_cpu_model_description, "model",
"The model to use for the CPU");
- declare_model_flag("storage/model", "default", &_sg_cfg_cb__storage_mode, surf_storage_model_description, "model",
+ declare_model_flag("disk/model", "default", &_sg_cfg_cb__disk_model, surf_disk_model_description, "model",
+ "The model to use for the disk");
+
+ declare_model_flag("storage/model", "default", &_sg_cfg_cb__storage_model, surf_storage_model_description, "model",
"The model to use for the storage");
declare_model_flag("network/model", "LV08", &_sg_cfg_cb__network_model, surf_network_model_description, "model",
"no");
simgrid::config::alias("network/maxmin-selective-update", {"network/maxmin_selective_update"});
- extern bool _sg_do_verbose_exit;
- simgrid::config::bind_flag(_sg_do_verbose_exit, "verbose-exit", "Activate the \"do nothing\" mode in Ctrl-C");
-
simgrid::config::declare_flag<int>("contexts/stack-size", "Stack size of contexts in KiB (not with threads)",
8 * 1024, [](int value) { smx_context_stack_size = value * 1024; });
simgrid::config::alias("contexts/stack-size", {"contexts/stack_size"});
#if HAVE_SMPI
simgrid::config::declare_flag<double>("smpi/host-speed", "Speed of the host running the simulation (in flop/s). "
"Used to bench the operations.",
- 20000.0);
+ 20000.0, [](const double& val) {
+ xbt_assert(val > 0.0, "Invalid value (%f) for 'smpi/host-speed': it must be positive.", val);
+ });
simgrid::config::alias("smpi/host-speed", {"smpi/running_power", "smpi/running-power"});
simgrid::config::declare_flag<bool>("smpi/keep-temps", "Whether we should keep the generated temporary files.",
simgrid::config::declare_flag<double>("smpi/shared-malloc-blocksize",
"Size of the bogus file which will be created for global shared allocations",
1UL << 20);
+ simgrid::config::declare_flag<double>("smpi/auto-shared-malloc-thresh",
+ "Threshold size for the automatic sharing of memory",
+ 0);
+
simgrid::config::declare_flag<std::string>("smpi/shared-malloc-hugepage",
"Path to a mounted hugetlbfs, to use huge pages with shared malloc.", "");
simgrid::config::declare_flag<bool>("smpi/trace-call-location",
"Should filename and linenumber of MPI calls be traced?", false);
-
+ simgrid::config::declare_flag<bool>("smpi/trace-call-use-absolute-path",
+ "Should filenames for trace-call tracing be absolute or not?", false);
simgrid::config::declare_flag<int>(
"smpi/send-is-detached-thresh",
"Threshold of message size where MPI_Send stops behaving like MPI_Isend and becomes MPI_Ssend", 65536);
simgrid::config::declare_flag<bool>(
"exception/cutpath", "Whether to cut all path information from call traces, used e.g. in exceptions.", false);
- extern bool _sg_do_clean_atexit;
- simgrid::config::bind_flag(_sg_do_clean_atexit, "clean-atexit", {"clean_atexit"},
- "Whether to cleanup SimGrid at exit. Disable it if your code segfaults after its end.");
-
if (surf_path.empty())
simgrid::config::set_default<std::string>("path", "./");