4 #include <csignal> // std::sig_atomic_t
7 #include "named_object_list.h"
9 // These classes may use include options.h, so make forward declarations
10 class deployment_generator;
13 // Global parameters, shared by all the processes
17 extern const double load_ratio_threshold;
20 extern std::string program_name;
21 extern int help_requested;
22 extern bool version_requested;
23 extern int option_x; // hidden option, for debugging purpose
25 // Simulation parameters
27 extern volatile std::sig_atomic_t exit_request;
29 // Platform and deployment
30 extern std::string platform_file;
31 extern std::string deployment_file;
33 // Automatic deployment
36 extern std::string topology;
37 extern unsigned nhosts;
39 extern bool random_distribution;
40 extern unsigned long random_seed;
43 // Load balancing algorithm
44 extern std::string loba_algo;
45 extern bool bookkeeping;
46 extern bool egocentric;
47 extern double min_transfer_amount;
48 extern double max_transfer_amount;
49 extern double min_lb_iter_duration;
50 extern bool integer_transfer;
52 // Application parameters
53 extern cost_func comp_cost;
54 extern cost_func comm_cost;
55 extern double min_comp_iter_duration;
56 extern unsigned comp_iter_delay;
57 extern double comp_time_delay;
59 // Parameters for the end of the simulation
60 extern unsigned lb_maxiter;
61 extern unsigned comp_maxiter;
62 extern double time_limit;
63 extern bool exit_on_close;
65 // Named parameters lists
66 extern struct loba_algorithms_type:
67 public named_object_list2<process, int, char** > {
68 loba_algorithms_type();
71 extern struct topologies_type:
72 public named_object_list<deployment_generator> {
77 bool parse_args(int* argc, char* argv[]);