command_line_handling

The contents of this module can be included with the header hpx/modules/command_line_handling.hpp. These headers may be used by user-code but are not guaranteed stable (neither header location nor contents). You are using these at your own risk. If you wish to use non-public functionality from a module we strongly suggest only including the module header hpx/modules/command_line_handling.hpp, not the particular header in which the functionality you would like to use is defined. See Public API for a list of names that are part of the public HPX API.

Header hpx/command_line_handling/command_line_handling.hpp

namespace hpx
namespace util

Functions

std::size_t get_num_high_priority_queues(util::command_line_handling const &cfg, std::size_t num_threads)
std::string get_affinity_domain(util::command_line_handling const &cfg)
std::size_t get_affinity_description(util::command_line_handling const &cfg, std::string &affinity_desc)
std::size_t get_pu_offset(util::command_line_handling const &cfg)
std::size_t get_pu_step(util::command_line_handling const &cfg)
struct command_line_handling
#include <command_line_handling.hpp>

Public Functions

command_line_handling()
int call(hpx::program_options::options_description const &desc_cmdline, int argc, char **argv, std::vector<std::shared_ptr<components::component_registry_base>> &component_registries)

Public Members

hpx::program_options::variables_map vm_
util::runtime_configuration rtcfg_
std::vector<std::string> ini_config_
util::function_nonser<int(hpx::program_options::variables_map &vm)> hpx_main_f_
std::size_t node_
std::size_t num_threads_
std::size_t num_cores_
std::size_t num_localities_
std::size_t pu_step_
std::size_t pu_offset_
std::string queuing_
std::string affinity_domain_
std::string affinity_bind_
std::size_t numa_sensitive_
bool use_process_mask_
bool cmd_line_parsed_
bool info_printed_
bool version_printed_
int parse_result_

Protected Functions

bool handle_arguments(util::manage_config &cfgmap, hpx::program_options::variables_map &vm, std::vector<std::string> &ini_config, std::size_t &node, bool initial = false)
void enable_logging_settings(hpx::program_options::variables_map &vm, std::vector<std::string> &ini_config)
void store_command_line(int argc, char **argv)
void store_unregistered_options(std::string const &cmd_name, std::vector<std::string> const &unregistered_options)
bool handle_help_options(hpx::program_options::options_description const &help)
void handle_attach_debugger()
std::vector<std::string> preprocess_config_settings(int argc, char **argv)

Header hpx/command_line_handling/parse_command_line.hpp

namespace hpx
namespace util

Enums

enum commandline_error_mode

Values:

return_on_error
rethrow_on_error
allow_unregistered
report_missing_config_file = 0x80

Functions

bool parse_commandline(hpx::util::section const &rtcfg, hpx::program_options::options_description const &app_options, std::string const &cmdline, hpx::program_options::variables_map &vm, std::size_t node, int error_mode = return_on_error, hpx::runtime_mode mode = runtime_mode::default_, hpx::program_options::options_description *visible = nullptr, std::vector<std::string> *unregistered_options = nullptr)
bool parse_commandline(hpx::util::section const &rtcfg, hpx::program_options::options_description const &app_options, std::string const &arg0, std::vector<std::string> const &args, hpx::program_options::variables_map &vm, std::size_t node, int error_mode = return_on_error, hpx::runtime_mode mode = runtime_mode::default_, hpx::program_options::options_description *visible = nullptr, std::vector<std::string> *unregistered_options = nullptr)
std::string reconstruct_command_line(hpx::program_options::variables_map const &vm)