runtime_configuration¶
The contents of this module can be included with the header
hpx/modules/runtime_configuration.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/runtime_configuration.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.
-
namespace
hpx
-
namespace
agas
-
namespace
Defines
-
HPX_REGISTER_COMMANDLINE_REGISTRY
(RegistryType, componentname)¶ The macro HPX_REGISTER_COMMANDLINE_REGISTRY is used to register the given component factory with Hpx.Plugin. This macro has to be used for each of the components.
-
HPX_REGISTER_COMMANDLINE_REGISTRY_DYNAMIC
(RegistryType, componentname)¶
-
HPX_REGISTER_COMMANDLINE_OPTIONS
()¶ The macro HPX_REGISTER_COMMANDLINE_OPTIONS is used to define the required Hpx.Plugin entry point for the command line option registry. This macro has to be used in not more than one compilation unit of a component module.
-
HPX_REGISTER_COMMANDLINE_OPTIONS_DYNAMIC
()¶
-
namespace
hpx
-
namespace
components
-
struct
component_commandline_base
¶ - #include <component_commandline_base.hpp>
The component_commandline_base has to be used as a base class for all component command-line line handling registries.
Public Functions
-
virtual
~component_commandline_base
()¶
-
virtual hpx::program_options::options_description
add_commandline_options
() = 0¶ Return any additional command line options valid for this component.
- Return
The module is expected to fill a options_description object with any additional command line options this component will handle.
- Note
This function will be executed by the runtime system during system startup.
-
virtual
-
struct
-
namespace
Defines
-
HPX_REGISTER_COMPONENT_FACTORY
(componentname)¶ This macro is used to register the given component factory with Hpx.Plugin. This macro has to be used for each of the component factories.
-
HPX_REGISTER_COMPONENT_MODULE
()¶ This macro is used to define the required Hpx.Plugin entry points. This macro has to be used in exactly one compilation unit of a component module.
-
HPX_REGISTER_COMPONENT_MODULE_DYNAMIC
()¶
Defines
-
HPX_REGISTER_COMPONENT_REGISTRY
(RegistryType, componentname)¶ This macro is used to register the given component factory with Hpx.Plugin. This macro has to be used for each of the components.
-
HPX_REGISTER_COMPONENT_REGISTRY_DYNAMIC
(RegistryType, componentname)¶
-
HPX_REGISTER_REGISTRY_MODULE
()¶ This macro is used to define the required Hpx.Plugin entry points. This macro has to be used in exactly one compilation unit of a component module.
-
HPX_REGISTER_REGISTRY_MODULE_DYNAMIC
()¶
-
namespace
hpx
-
namespace
components
-
struct
component_registry_base
¶ - #include <component_registry_base.hpp>
The component_registry_base has to be used as a base class for all component registries.
Public Functions
-
virtual
~component_registry_base
()¶
-
virtual bool
get_component_info
(std::vector<std::string> &fillini, std::string const &filepath, bool is_static = false) = 0¶ Return the ini-information for all contained components.
- Return
Returns true if the parameter fillini has been successfully initialized with the registry data of all implemented in this module.
- Parameters
fillini
: [in, out] The module is expected to fill this vector with the ini-information (one line per vector element) for all components implemented in this module.
-
virtual void
register_component_type
() = 0¶ Return the unique identifier of the component type this factory is responsible for.
- Return
Returns the unique identifier of the component type this factory instance is responsible for. This function throws on any error.
- Parameters
locality
: [in] The id of the locality this factory is responsible for.agas_client
: [in] The AGAS client to use for component id registration (if needed).
-
virtual
-
struct
-
namespace
-
namespace
hpx
-
namespace
util
Functions
-
std::vector<std::shared_ptr<components::component_registry_base>>
load_component_factory_static
(util::section &ini, std::string name, hpx::util::plugin::get_plugins_list_type get_factory, error_code &ec = throws)¶
-
std::vector<std::shared_ptr<components::component_registry_base>>
-
namespace
Defines
-
HPX_REGISTER_PLUGIN_BASE_REGISTRY
(PluginType, name)¶ This macro is used to register the given component factory with Hpx.Plugin. This macro has to be used for each of the components.
-
HPX_REGISTER_PLUGIN_REGISTRY_MODULE
()¶ This macro is used to define the required Hpx.Plugin entry points. This macro has to be used in exactly one compilation unit of a component module.
-
HPX_REGISTER_PLUGIN_REGISTRY_MODULE_DYNAMIC
()¶
-
namespace
hpx
-
namespace
plugins
¶ -
struct
plugin_registry_base
¶ - #include <plugin_registry_base.hpp>
The plugin_registry_base has to be used as a base class for all plugin registries.
Public Functions
-
virtual
~plugin_registry_base
()¶
-
virtual bool
get_plugin_info
(std::vector<std::string> &fillini) = 0¶ Return the configuration information for any plugin implemented by this module
- Return
Returns true if the parameter fillini has been successfully initialized with the registry data of all implemented in this module.
- Parameters
fillini
: [in, out] The module is expected to fill this vector with the ini-information (one line per vector element) for all plugins implemented in this module.
-
virtual void
init
(int*, char***, util::runtime_configuration&)¶
-
virtual
-
struct
-
namespace
-
namespace
hpx
-
namespace
util
-
class
runtime_configuration
: public section¶ Public Functions
-
runtime_configuration
(char const *argv0, runtime_mode mode)¶
-
void
load_components_static
(std::vector<components::static_factory_load_data_type> const &static_modules)¶
-
agas::service_mode
get_agas_service_mode
() const¶
-
bool
enable_networking
() const¶
-
bool
get_agas_caching_mode
() const¶
-
bool
get_agas_range_caching_mode
() const¶
-
bool
load_application_configuration
(char const *filename, error_code &ec = throws)¶
-
bool
get_itt_notify_mode
() const¶
-
bool
enable_lock_detection
() const¶
-
bool
enable_global_lock_detection
() const¶
-
bool
enable_minimal_deadlock_detection
() const¶
-
bool
enable_spinlock_deadlock_detection
() const¶
-
std::ptrdiff_t
get_stack_size
(threads::thread_stacksize stacksize) const¶
Public Members
-
runtime_mode
mode_
¶
Private Functions
-
std::ptrdiff_t
init_stack_size
(char const *entryname, char const *defaultvaluestr, std::ptrdiff_t defaultvalue) const¶
-
void
pre_initialize_ini
()¶
-
void
post_initialize_ini
(std::string &hpx_ini_file, std::vector<std::string> const &cmdline_ini_defs)¶
-
void
pre_initialize_logging_ini
()¶
-
void
reconfigure
()¶
Private Members
-
bool
need_to_call_pre_initialize
¶
-
-
class
-
namespace
-
namespace
hpx
Enums
-
enum
runtime_mode
¶ A HPX runtime can be executed in two different modes: console mode and worker mode.
Values:
-
invalid
= -1¶
-
console
= 0¶ The runtime is the console locality.
-
worker
= 1¶ The runtime is a worker locality.
-
connect
= 2¶ The runtime is a worker locality connecting late
-
local
= 3 The runtime is fully local.
-
default_
= 4¶ The runtime mode will be determined based on the command line arguments
-
last
¶
-
Functions
-
char const *
get_runtime_mode_name
(runtime_mode state)¶ Get the readable string representing the name of the given runtime_mode constant.
-
runtime_mode
get_runtime_mode_from_name
(std::string const &mode)¶ Returns the internal representation (runtime_mode constant) from the readable string representing the name.
This represents the internal representation from the readable string representing the name.
- Parameters
mode
: this represents the runtime mode
-
enum
Defines
-
HPX_DECLARE_FACTORY_STATIC
(name, base)¶
-
HPX_DEFINE_FACTORY_STATIC
(module, name, base)¶
-
HPX_INIT_REGISTRY_MODULE_STATIC
(name, base)¶
-
HPX_INIT_REGISTRY_FACTORY_STATIC
(name, componentname, base)¶
-
HPX_INIT_REGISTRY_COMMANDLINE_STATIC
(name, base)¶
-
HPX_INIT_REGISTRY_STARTUP_SHUTDOWN_STATIC
(name, base)¶
-
namespace
hpx
-
namespace
components
Functions
-
void
init_registry_module
(static_factory_load_data_type const&)¶
-
void
init_registry_factory
(static_factory_load_data_type const&)¶
-
void
init_registry_commandline
(static_factory_load_data_type const&)¶
-
void
init_registry_startup_shutdown
(static_factory_load_data_type const&)¶
-
struct
static_factory_load_data_type
¶
-
void
-
namespace