execution¶
#include <hpx/traits/is_execution_policy.hpp>
¶
-
namespace
hpx
-
namespace
parallel
-
namespace
execution
-
template <typename T>
structis_async_execution_policy
: public execution::detail::is_async_execution_policy<hpx::util::decay<T>::type>¶ - #include <is_execution_policy.hpp>
Extension: Detect whether given execution policy makes algorithms asynchronous
- The type is_async_execution_policy can be used to detect asynchronous execution policies for the purpose of excluding function signatures from otherwise ambiguous overload resolution participation.
- If T is the type of a standard or implementation-defined execution policy, is_async_execution_policy<T> shall be publicly derived from integral_constant<bool, true>, otherwise from integral_constant<bool, false>.
- The behavior of a program that adds specializations for is_async_execution_policy is undefined.
-
template <typename T>
structis_execution_policy
: public execution::detail::is_execution_policy<hpx::util::decay<T>::type>¶ - #include <is_execution_policy.hpp>
- The type is_execution_policy can be used to detect execution policies for the purpose of excluding function signatures from otherwise ambiguous overload resolution participation.
- If T is the type of a standard or implementation-defined execution policy, is_execution_policy<T> shall be publicly derived from integral_constant<bool, true>, otherwise from integral_constant<bool, false>.
- The behavior of a program that adds specializations for is_execution_policy is undefined.
-
template <typename T>
structis_parallel_execution_policy
: public execution::detail::is_parallel_execution_policy<hpx::util::decay<T>::type>¶ - #include <is_execution_policy.hpp>
Extension: Detect whether given execution policy enables parallelization
- The type is_parallel_execution_policy can be used to detect parallel execution policies for the purpose of excluding function signatures from otherwise ambiguous overload resolution participation.
- If T is the type of a standard or implementation-defined execution policy, is_parallel_execution_policy<T> shall be publicly derived from integral_constant<bool, true>, otherwise from integral_constant<bool, false>.
- The behavior of a program that adds specializations for is_parallel_execution_policy is undefined.
-
template <typename T>
structis_sequenced_execution_policy
: public execution::detail::is_sequenced_execution_policy<hpx::util::decay<T>::type>¶ - #include <is_execution_policy.hpp>
Extension: Detect whether given execution policy does not enable parallelization
- The type is_sequenced_execution_policy can be used to detect non-parallel execution policies for the purpose of excluding function signatures from otherwise ambiguous overload resolution participation.
- If T is the type of a standard or implementation-defined execution policy, is_sequenced_execution_policy<T> shall be publicly derived from integral_constant<bool, true>, otherwise from integral_constant<bool, false>.
- The behavior of a program that adds specializations for is_sequenced_execution_policy is undefined.
-
template <typename T>
-
namespace
-
namespace
#include <hpx/traits/is_executor_parameters.hpp>
¶
-
template <typename Executor>
template<>
structextract_executor_parameters
<Executor, typename hpx::util::always_void<typename Executor::executor_parameters_type>::type>¶ Public Types
-
template<>
usingtype
= typename Executor::executor_parameters_type¶
-
template<>
-
template <typename Parameters>
template<>
structextract_has_variable_chunk_size
<Parameters, typename hpx::util::always_void<typename Parameters::has_variable_chunk_size>::type>¶ Public Types
-
template<>
usingtype
= typename Parameters::has_variable_chunk_size¶
-
template<>
-
namespace
hpx
-
namespace
parallel
-
namespace
execution
Typedefs
-
using
hpx::parallel::execution::is_executor_parameters_t = typedef typename is_executor_parameters<T>::type
-
template <typename Executor, typename Enable = void>
structextract_executor_parameters
¶ Public Types
-
template<>
usingtype
= sequential_executor_parameters¶
-
template<>
-
template <typename Executor>
template<>
structextract_executor_parameters
<Executor, typename hpx::util::always_void<typename Executor::executor_parameters_type>::type> Public Types
-
template<>
usingtype
= typename Executor::executor_parameters_type
-
template<>
-
template <typename Parameters, typename Enable = void>
structextract_has_variable_chunk_size
¶
-
template <typename Parameters>
template<>
structextract_has_variable_chunk_size
<Parameters, typename hpx::util::always_void<typename Parameters::has_variable_chunk_size>::type> Public Types
-
template<>
usingtype
= typename Parameters::has_variable_chunk_size
-
template<>
-
using
-
namespace
-
namespace
traits
Typedefs
-
using
hpx::traits::is_executor_parameters_t = typedef typename is_executor_parameters<T>::type
-
using
-
namespace
#include <hpx/traits/executor_traits.hpp>
¶
-
namespace
hpx
-
namespace
parallel
-
namespace
execution
-
template <typename Executor>
structexecutor_context
¶
-
template <typename Executor>
structexecutor_execution_category
¶ Public Types
-
template<>
usingtype
= hpx::util::detected_or_t<unsequenced_execution_tag, execution_category, Executor>¶
Private Types
-
template<>
usingexecution_category
= typename T::execution_category¶
-
template<>
-
template <typename Executor>
structexecutor_index
¶ Public Types
-
template<>
usingtype
= hpx::util::detected_or_t<typename executor_shape<Executor>::type, index_type, Executor>¶
Private Types
-
template<>
usingindex_type
= typename T::index_type¶
-
template<>
-
template <typename Executor>
structexecutor_parameters_type
¶ Public Types
-
template<>
usingtype
= hpx::util::detected_or_t<parallel::execution::static_chunk_size, parameters_type, Executor>¶
Private Types
-
template<>
usingparameters_type
= typename T::parameters_type¶
-
template<>
-
template <typename Executor>
-
namespace
-
namespace
traits
Typedefs
-
using
hpx::traits::executor_context_t = typedef typename executor_context<Executor>::type
-
using
hpx::traits::executor_execution_category_t = typedef typename executor_execution_category<Executor>::type
-
using
hpx::traits::executor_shape_t = typedef typename executor_shape<Executor>::type
-
using
hpx::traits::executor_index_t = typedef typename executor_index<Executor>::type
-
using
hpx::traits::executor_parameters_type_t = typedef typename executor_parameters_type<Executor>::type
-
using
-
namespace
#include <hpx/traits/is_timed_executor.hpp>
¶
-
namespace
hpx
-
namespace
parallel
-
namespace
execution
Typedefs
-
using
hpx::parallel::execution::is_timed_executor_t = typedef typename is_timed_executor<T>::type
-
using
-
namespace
-
namespace
#include <hpx/traits/is_executor.hpp>
¶
-
namespace
hpx
-
namespace
parallel
-
namespace
execution
Typedefs
-
using
hpx::parallel::execution::is_one_way_executor_t = typedef typename is_one_way_executor<T>::type
-
using
hpx::parallel::execution::is_never_blocking_one_way_executor_t = typedef typename is_never_blocking_one_way_executor<T>::type
-
using
hpx::parallel::execution::is_bulk_one_way_executor_t = typedef typename is_bulk_one_way_executor<T>::type
-
using
hpx::parallel::execution::is_two_way_executor_t = typedef typename is_two_way_executor<T>::type
-
using
hpx::parallel::execution::is_bulk_two_way_executor_t = typedef typename is_bulk_two_way_executor<T>::type
-
using
-
namespace
-
namespace
traits
Typedefs
-
using
hpx::traits::is_one_way_executor_t = typedef typename is_one_way_executor<T>::type
-
using
hpx::traits::is_never_blocking_one_way_executor_t = typedef typename is_never_blocking_one_way_executor<T>::type
-
using
hpx::traits::is_bulk_one_way_executor_t = typedef typename is_bulk_one_way_executor<T>::type
-
using
hpx::traits::is_two_way_executor_t = typedef typename is_two_way_executor<T>::type
-
using
hpx::traits::is_bulk_two_way_executor_t = typedef typename is_bulk_two_way_executor<T>::type
-
using
hpx::traits::is_executor_any_t = typedef typename is_executor_any<T>::type
-
using
-
namespace
#include <hpx/parallel/execution_policy_fwd.hpp>
¶
-
namespace
hpx
-
namespace
parallel
-
namespace
execution
-
template <typename Executor, typename Parameters>
structparallel_policy_shim
: public hpx::parallel::execution::parallel_policy¶ - #include <execution_policy.hpp>
The class parallel_policy_shim is an execution policy type used as a unique type to disambiguate parallel algorithm overloading and indicate that a parallel algorithm’s execution may be parallelized.
-
template <typename Executor, typename Parameters>
structparallel_task_policy_shim
: public hpx::parallel::execution::parallel_task_policy¶ - #include <execution_policy.hpp>
Extension: The class parallel_task_policy_shim is an execution policy type used as a unique type to disambiguate parallel algorithm overloading based on combining a underlying parallel_task_policy and an executor and indicate that a parallel algorithm’s execution may be parallelized.
-
template <typename Executor, typename Parameters>
structsequenced_policy_shim
: public hpx::parallel::execution::sequenced_policy¶ - #include <execution_policy.hpp>
The class sequenced_policy is an execution policy type used as a unique type to disambiguate parallel algorithm overloading and require that a parallel algorithm’s execution may not be parallelized.
-
template <typename Executor, typename Parameters>
structsequenced_task_policy_shim
: public hpx::parallel::execution::sequenced_task_policy¶ - #include <execution_policy.hpp>
Extension: The class sequenced_task_policy_shim is an execution policy type used as a unique type to disambiguate parallel algorithm overloading based on combining a underlying sequenced_task_policy and an executor and indicate that a parallel algorithm’s execution may not be parallelized (has to run sequentially).
The algorithm returns a future representing the result of the corresponding algorithm when invoked with the sequenced_policy.
-
template <typename Executor, typename Parameters>
-
namespace
-
namespace
#include <hpx/parallel/executors.hpp>
¶
#include <hpx/parallel/execution.hpp>
¶
#include <hpx/parallel/execution_policy.hpp>
¶
-
namespace
hpx
-
namespace
parallel
-
namespace
execution
Variables
-
task_policy_tag HPX_CONSTEXPR_OR_CONST hpx::parallel::execution::task
Default sequential execution policy object.
-
HPX_STATIC_CONSTEXPR sequenced_policy hpx::parallel::execution::seq
Default sequential execution policy object.
-
HPX_STATIC_CONSTEXPR parallel_policy hpx::parallel::execution::par
Default parallel execution policy object.
-
HPX_STATIC_CONSTEXPR parallel_unsequenced_policy hpx::parallel::execution::par_unseq
Default vector execution policy object.
-
struct
parallel_policy
¶ - #include <execution_policy.hpp>
The class parallel_policy is an execution policy type used as a unique type to disambiguate parallel algorithm overloading and indicate that a parallel algorithm’s execution may be parallelized.
Subclassed by hpx::parallel::execution::parallel_policy_shim< Executor, Parameters >
Public Types
-
typedef parallel_executor
executor_type
¶ The type of the executor associated with this execution policy.
-
typedef execution::extract_executor_parameters<executor_type>::type
executor_parameters_type
¶ The type of the associated executor parameters object which is associated with this execution policy
-
typedef parallel_execution_tag
execution_category
¶ The category of the execution agents created by this execution policy.
Public Functions
-
parallel_task_policy
operator()
(task_policy_tag) const¶ Create a new parallel_policy referencing a chunk size.
- Return
- The new parallel_policy
- Parameters
tag
: [in] Specify that the corresponding asynchronous execution policy should be used
-
template <typename Executor>
rebind_executor<parallel_policy, Executor, executor_parameters_type>::typeon
(Executor &&exec) const¶ Create a new parallel_policy referencing an executor and a chunk size.
- Return
- The new parallel_policy
- Parameters
exec
: [in] The executor to use for the execution of the parallel algorithm the returned execution policy is used with
-
template <typename... Parameters, typename ParametersType = typename executor_parameters_join<Parameters...>::type>
rebind_executor<parallel_policy, executor_type, ParametersType>::typewith
(Parameters&&... params) const¶ Create a new parallel_policy from the given execution parameters
- Note
- Requires: is_executor_parameters<Parameters>::value is true
- Return
- The new parallel_policy
- Template Parameters
Parameters
: The type of the executor parameters to associate with this execution policy.
- Parameters
params
: [in] The executor parameters to use for the execution of the parallel algorithm the returned execution policy is used with.
-
executor_type &
executor
()¶ Return the associated executor object.
-
executor_type const &
executor
() const¶ Return the associated executor object.
-
executor_parameters_type &
parameters
()¶ Return the associated executor parameters object.
-
executor_parameters_type const &
parameters
() const¶ Return the associated executor parameters object.
Private Functions
-
template <typename Archive>
voidserialize
(Archive &ar, const unsigned int version)¶
Friends
-
friend
hpx::parallel::execution::hpx::serialization::access
-
template <typename Executor_, typename Parameters_>
structrebind
¶ - #include <execution_policy.hpp>
Rebind the type of executor used by this execution policy. The execution category of Executor shall not be weaker than that of this execution policy
Public Types
-
typedef parallel_policy_shim<Executor_, Parameters_>
type
¶ The type of the rebound execution policy.
-
typedef parallel_policy_shim<Executor_, Parameters_>
-
typedef parallel_executor
-
struct
parallel_task_policy
¶ - #include <execution_policy.hpp>
Extension: The class parallel_task_policy is an execution policy type used as a unique type to disambiguate parallel algorithm overloading and indicate that a parallel algorithm’s execution may be parallelized.
The algorithm returns a future representing the result of the corresponding algorithm when invoked with the parallel_policy.
Subclassed by hpx::parallel::execution::parallel_task_policy_shim< Executor, Parameters >
Public Types
-
typedef parallel_executor
executor_type
¶ The type of the executor associated with this execution policy.
-
typedef execution::extract_executor_parameters<executor_type>::type
executor_parameters_type
¶ The type of the associated executor parameters object which is associated with this execution policy
-
typedef parallel_execution_tag
execution_category
¶ The category of the execution agents created by this execution policy.
Public Functions
-
parallel_task_policy
operator()
(task_policy_tag) const¶ Create a new parallel_task_policy from itself
- Return
- The new parallel_task_policy
- Parameters
tag
: [in] Specify that the corresponding asynchronous execution policy should be used
-
template <typename Executor>
rebind_executor<parallel_task_policy, Executor, executor_parameters_type>::typeon
(Executor &&exec) const¶ Create a new parallel_task_policy from given executor
- Note
- Requires: is_executor<Executor>::value is true
- Return
- The new parallel_task_policy
- Template Parameters
Executor
: The type of the executor to associate with this execution policy.
- Parameters
exec
: [in] The executor to use for the execution of the parallel algorithm the returned execution policy is used with.
-
template <typename... Parameters, typename ParametersType = typename executor_parameters_join<Parameters...>::type>
rebind_executor<parallel_task_policy, executor_type, ParametersType>::typewith
(Parameters&&... params) const¶ Create a new parallel_policy_shim from the given execution parameters
- Note
- Requires: all parameters are executor_parameters, different parameter types can’t be duplicated
- Return
- The new parallel_policy_shim
- Template Parameters
Parameters
: The type of the executor parameters to associate with this execution policy.
- Parameters
params
: [in] The executor parameters to use for the execution of the parallel algorithm the returned execution policy is used with.
-
executor_type &
executor
()¶ Return the associated executor object.
-
executor_type const &
executor
() const¶ Return the associated executor object.
-
executor_parameters_type &
parameters
()¶ Return the associated executor parameters object.
-
executor_parameters_type const &
parameters
() const¶ Return the associated executor parameters object.
Private Functions
-
template <typename Archive>
voidserialize
(Archive &ar, const unsigned int version)¶
Friends
-
friend
hpx::parallel::execution::hpx::serialization::access
-
template <typename Executor_, typename Parameters_>
structrebind
¶ - #include <execution_policy.hpp>
Rebind the type of executor used by this execution policy. The execution category of Executor shall not be weaker than that of this execution policy
Public Types
-
typedef parallel_task_policy_shim<Executor_, Parameters_>
type
¶ The type of the rebound execution policy.
-
typedef parallel_task_policy_shim<Executor_, Parameters_>
-
typedef parallel_executor
-
struct
parallel_unsequenced_policy
¶ - #include <execution_policy.hpp>
The class parallel_unsequenced_policy is an execution policy type used as a unique type to disambiguate parallel algorithm overloading and indicate that a parallel algorithm’s execution may be vectorized.
Public Types
-
typedef parallel_executor
executor_type
¶ The type of the executor associated with this execution policy.
-
typedef execution::extract_executor_parameters<executor_type>::type
executor_parameters_type
¶ The type of the associated executor parameters object which is associated with this execution policy
-
typedef parallel_execution_tag
execution_category
¶ The category of the execution agents created by this execution policy.
Public Functions
-
parallel_unsequenced_policy
operator()
(task_policy_tag) const¶ Create a new parallel_unsequenced_policy from itself
- Return
- The new parallel_unsequenced_policy
- Parameters
tag
: [in] Specify that the corresponding asynchronous execution policy should be used
-
executor_type &
executor
()¶ Return the associated executor object.
-
executor_type const &
executor
() const¶ Return the associated executor object.
-
executor_parameters_type &
parameters
()¶ Return the associated executor parameters object.
-
executor_parameters_type const &
parameters
() const¶ Return the associated executor parameters object.
Private Functions
-
template <typename Archive>
voidserialize
(Archive &ar, const unsigned int version)¶
Friends
-
friend
hpx::parallel::execution::hpx::serialization::access
-
typedef parallel_executor
-
struct
sequenced_policy
¶ - #include <execution_policy.hpp>
The class sequenced_policy is an execution policy type used as a unique type to disambiguate parallel algorithm overloading and require that a parallel algorithm’s execution may not be parallelized.
Subclassed by hpx::parallel::execution::sequenced_policy_shim< Executor, Parameters >
Public Types
-
typedef sequenced_executor
executor_type
¶ The type of the executor associated with this execution policy.
-
typedef execution::extract_executor_parameters<executor_type>::type
executor_parameters_type
¶ The type of the associated executor parameters object which is associated with this execution policy
-
typedef sequenced_execution_tag
execution_category
¶ The category of the execution agents created by this execution policy.
Public Functions
-
sequenced_task_policy
operator()
(task_policy_tag) const¶ Create a new sequenced_task_policy.
- Return
- The new sequenced_task_policy
- Parameters
tag
: [in] Specify that the corresponding asynchronous execution policy should be used
-
template <typename Executor>
rebind_executor<sequenced_policy, Executor, executor_parameters_type>::typeon
(Executor &&exec) const¶ Create a new sequenced_policy from the given executor
- Note
- Requires: is_executor<Executor>::value is true
- Return
- The new sequenced_policy
- Template Parameters
Executor
: The type of the executor to associate with this execution policy.
- Parameters
exec
: [in] The executor to use for the execution of the parallel algorithm the returned execution policy is used with.
-
template <typename... Parameters, typename ParametersType = typename executor_parameters_join<Parameters...>::type>
rebind_executor<sequenced_policy, executor_type, ParametersType>::typewith
(Parameters&&... params) const¶ Create a new sequenced_policy from the given execution parameters
- Note
- Requires: all parameters are executor_parameters, different parameter types can’t be duplicated
- Return
- The new sequenced_policy
- Template Parameters
Parameters
: The type of the executor parameters to associate with this execution policy.
- Parameters
params
: [in] The executor parameters to use for the execution of the parallel algorithm the returned execution policy is used with.
-
executor_type &
executor
()¶ Return the associated executor object. Return the associated executor object.
-
executor_type const &
executor
() const¶ Return the associated executor object.
-
executor_parameters_type &
parameters
()¶ Return the associated executor parameters object.
-
executor_parameters_type const &
parameters
() const¶ Return the associated executor parameters object.
Private Functions
-
template <typename Archive>
voidserialize
(Archive &ar, const unsigned int version)¶
Friends
-
friend
hpx::parallel::execution::hpx::serialization::access
-
template <typename Executor_, typename Parameters_>
structrebind
¶ - #include <execution_policy.hpp>
Rebind the type of executor used by this execution policy. The execution category of Executor shall not be weaker than that of this execution policy
Public Types
-
typedef sequenced_policy_shim<Executor_, Parameters_>
type
¶ The type of the rebound execution policy.
-
typedef sequenced_policy_shim<Executor_, Parameters_>
-
typedef sequenced_executor
-
struct
sequenced_task_policy
¶ - #include <execution_policy.hpp>
Extension: The class sequenced_task_policy is an execution policy type used as a unique type to disambiguate parallel algorithm overloading and indicate that a parallel algorithm’s execution may not be parallelized (has to run sequentially).
The algorithm returns a future representing the result of the corresponding algorithm when invoked with the sequenced_policy.
Subclassed by hpx::parallel::execution::sequenced_task_policy_shim< Executor, Parameters >
Public Types
-
typedef sequenced_executor
executor_type
¶ The type of the executor associated with this execution policy.
-
typedef execution::extract_executor_parameters<executor_type>::type
executor_parameters_type
¶ The type of the associated executor parameters object which is associated with this execution policy
-
typedef sequenced_execution_tag
execution_category
¶ The category of the execution agents created by this execution policy.
Public Functions
-
sequenced_task_policy
operator()
(task_policy_tag) const¶ Create a new sequenced_task_policy from itself
- Return
- The new sequenced_task_policy
- Parameters
tag
: [in] Specify that the corresponding asynchronous execution policy should be used
-
template <typename Executor>
rebind_executor<sequenced_task_policy, Executor, executor_parameters_type>::typeon
(Executor &&exec) const¶ Create a new sequenced_task_policy from the given executor
- Note
- Requires: is_executor<Executor>::value is true
- Return
- The new sequenced_task_policy
- Template Parameters
Executor
: The type of the executor to associate with this execution policy.
- Parameters
exec
: [in] The executor to use for the execution of the parallel algorithm the returned execution policy is used with.
-
template <typename... Parameters, typename ParametersType = typename executor_parameters_join<Parameters...>::type>
rebind_executor<sequenced_task_policy, executor_type, ParametersType>::typewith
(Parameters&&... params) const¶ Create a new sequenced_task_policy from the given execution parameters
- Note
- Requires: all parameters are executor_parameters, different parameter types can’t be duplicated
- Return
- The new sequenced_task_policy
- Template Parameters
Parameters
: The type of the executor parameters to associate with this execution policy.
- Parameters
params
: [in] The executor parameters to use for the execution of the parallel algorithm the returned execution policy is used with.
-
executor_type &
executor
()¶ Return the associated executor object.
-
executor_type const &
executor
() const¶ Return the associated executor object.
-
executor_parameters_type &
parameters
()¶ Return the associated executor parameters object.
-
executor_parameters_type const &
parameters
() const¶ Return the associated executor parameters object.
Private Functions
-
template <typename Archive>
voidserialize
(Archive &ar, const unsigned int version)¶
Friends
-
friend
hpx::parallel::execution::hpx::serialization::access
-
template <typename Executor_, typename Parameters_>
structrebind
¶ - #include <execution_policy.hpp>
Rebind the type of executor used by this execution policy. The execution category of Executor shall not be weaker than that of this execution policy
Public Types
-
typedef sequenced_task_policy_shim<Executor_, Parameters_>
type
¶ The type of the rebound execution policy.
-
typedef sequenced_task_policy_shim<Executor_, Parameters_>
-
typedef sequenced_executor
-
-
namespace
-
namespace
#include <hpx/parallel/executor_parameters.hpp>
¶
#include <hpx/parallel/exception_list.hpp>
¶
#include <hpx/parallel/executors/execution_information_fwd.hpp>
¶
#include <hpx/parallel/executors/execution_parameters_fwd.hpp>
¶
#include <hpx/parallel/executors/default_executor.hpp>
¶
-
namespace
hpx
-
namespace
parallel
-
namespace
execution
Typedefs
-
using
hpx::parallel::execution::default_executor = typedef threads::executors::default_executor
Refers to the currently used base-executor.
-
using
-
namespace
-
namespace
#include <hpx/parallel/executors/service_executors.hpp>
¶
-
namespace
hpx
-
namespace
parallel
-
namespace
execution
Typedefs
-
using
hpx::parallel::execution::service_executor = typedef threads::executors::service_executor
A service_executor exposes one of the predefined HPX thread pools through an executor interface.
- Note
- All tasks executed by one of these executors will run on one of the OS-threads dedicated for the given thread pool. The tasks will not run as HPX-threads.
-
using
hpx::parallel::execution::io_pool_executor = typedef threads::executors::io_pool_executor
A io_pool_executor exposes the predefined HPX IO thread pool through an executor interface.
- Note
- All tasks executed by one of these executors will run on one of the OS-threads dedicated for the IO thread pool. The tasks will not run as HPX-threads.
-
using
hpx::parallel::execution::parcel_pool_executor = typedef threads::executors::parcel_pool_executor
A io_pool_executor exposes the predefined HPX parcel thread pool through an executor interface.
- Note
- All tasks executed by one of these executors will run on one of the OS-threads dedicated for the parcel thread pool. The tasks will not run as HPX-threads.
-
using
hpx::parallel::execution::timer_pool_executor = typedef threads::executors::timer_pool_executor
A io_pool_executor exposes the predefined HPX timer thread pool through an executor interface.
- Note
- All tasks executed by one of these executors will run on one of the OS-threads dedicated for the timer thread pool. The tasks will not run as HPX-threads.
-
using
hpx::parallel::execution::main_pool_executor = typedef threads::executors::main_pool_executor
A io_pool_executor exposes the predefined HPX main thread pool through an executor interface.
- Note
- All tasks executed by one of these executors will run on one of the OS-threads dedicated for the main thread pool. The tasks will not run as HPX-threads.
-
using
-
namespace
-
namespace
#include <hpx/parallel/executors/distribution_policy_executor.hpp>
¶
-
namespace
hpx
-
namespace
parallel
-
namespace
execution
Functions
-
template <typename DistPolicy>
distribution_policy_executor<typename hpx::util::decay<DistPolicy>::type>make_distribution_policy_executor
(DistPolicy &&policy)¶ Create a new distribution_policy_executor from the given distribution_policy.
- Parameters
policy
: The distribution_policy to create an executor from
-
template <typename DistPolicy>
classdistribution_policy_executor
¶ - #include <distribution_policy_executor.hpp>
A distribution_policy_executor creates groups of parallel execution agents which execute in threads implicitly created by the executor and placed on any of the associated localities.
- Template Parameters
DistPolicy
: The distribution policy type for which an executor should be created. The expression hpx::traits::is_distribution_policy<DistPolicy>::value must evaluate to true.
Public Functions
-
template <typename DistPolicy_, typename Enable = typename std::enable_if< !std::is_same<distribution_policy_executor, typename hpx::util::decay<DistPolicy_>::type>::value>::type>
distribution_policy_executor
(DistPolicy_ &&policy)¶ Create a new distribution_policy executor from the given distribution policy
- Parameters
policy
: The distribution_policy to create an executor from
Private Members
-
DistPolicy
policy_
¶
-
template <typename DistPolicy>
-
namespace
-
namespace
#include <hpx/parallel/executors/dynamic_chunk_size.hpp>
¶
-
namespace
hpx
-
namespace
parallel
-
namespace
execution
-
struct
dynamic_chunk_size
¶ - #include <dynamic_chunk_size.hpp>
Loop iterations are divided into pieces of size chunk_size and then dynamically scheduled among the threads; when a thread finishes one chunk, it is dynamically assigned another If chunk_size is not specified, the default chunk size is 1.
- Note
- This executor parameters type is equivalent to OpenMP’s DYNAMIC scheduling directive.
Public Functions
-
dynamic_chunk_size
(std::size_t chunk_size = 1)¶ Construct a dynamic_chunk_size executor parameters object
- Parameters
chunk_size
: [in] The optional chunk size to use as the number of loop iterations to schedule together. The default chunk size is 1.
-
struct
-
namespace
-
namespace
#include <hpx/parallel/executors/execution.hpp>
¶
#include <hpx/parallel/executors/timed_execution_fwd.hpp>
¶
#include <hpx/parallel/executors/auto_chunk_size.hpp>
¶
-
namespace
hpx
-
namespace
parallel
-
namespace
execution
-
struct
auto_chunk_size
¶ - #include <auto_chunk_size.hpp>
Loop iterations are divided into pieces and then assigned to threads. The number of loop iterations combined is determined based on measurements of how long the execution of 1% of the overall number of iterations takes. This executor parameters type makes sure that as many loop iterations are combined as necessary to run for the amount of time specified.
Public Functions
-
auto_chunk_size
()¶ Construct an auto_chunk_size executor parameters object
- Note
- Default constructed auto_chunk_size executor parameter types will use 80 microseconds as the minimal time for which any of the scheduled chunks should run.
-
auto_chunk_size
(hpx::util::steady_duration const &rel_time)¶ Construct an auto_chunk_size executor parameters object
- Parameters
rel_time
: [in] The time duration to use as the minimum to decide how many loop iterations should be combined.
-
-
struct
-
namespace
-
namespace
#include <hpx/parallel/executors/thread_timed_execution.hpp>
¶
-
namespace
hpx
-
namespace
threads
Functions
-
template <typename Executor, typename F, typename... Ts>
std::enable_if<hpx::traits::is_threads_executor<Executor>::value>::typepost_at
(Executor &&exec, hpx::util::steady_time_point const &abs_time, F &&f, Ts&&... ts)¶
-
template <typename Executor, typename F, typename... Ts>
std::enable_if<hpx::traits::is_threads_executor<Executor>::value>::typepost_after
(Executor &&exec, hpx::util::steady_duration const &rel_time, F &&f, Ts&&... ts)¶
-
template <typename Executor, typename F, typename... Ts>
std::enable_if<hpx::traits::is_threads_executor<Executor>::value, hpx::future<typename hpx::util::detail::invoke_deferred_result<F, Ts...>::type>>::typeasync_execute_at
(Executor &&exec, hpx::util::steady_time_point const &abs_time, F &&f, Ts&&... ts)¶
-
template <typename Executor, typename F, typename... Ts>
std::enable_if<hpx::traits::is_threads_executor<Executor>::value, hpx::future<typename hpx::util::detail::invoke_deferred_result<F, Ts...>::type>>::typeasync_execute_after
(Executor &&exec, hpx::util::steady_duration const &rel_time, F &&f, Ts&&... ts)¶
-
template <typename Executor, typename F, typename... Ts>
-
namespace
#include <hpx/parallel/executors/execution_parameters.hpp>
¶
-
namespace
hpx
-
namespace
parallel
-
namespace
execution
Functions
-
template <typename... Params>
executor_parameters_join<Params...>::typejoin_executor_parameters
(Params&&... params)¶
-
template <typename Param>
Param &&join_executor_parameters
(Param &¶m)¶
-
template <typename... Params>
structexecutor_parameters_join
¶
-
template <typename... Params>
-
namespace
-
namespace
#include <hpx/parallel/executors/thread_pool_attached_executors.hpp>
¶
-
namespace
hpx
-
namespace
parallel
-
namespace
execution
Typedefs
-
using
hpx::parallel::execution::local_priority_queue_attached_executor = typedef threads::executors::local_priority_queue_attached_executor
-
using
-
namespace
-
namespace
#include <hpx/parallel/executors/thread_pool_os_executors.hpp>
¶
-
namespace
hpx
-
namespace
parallel
-
namespace
execution
Typedefs
-
using
hpx::parallel::execution::local_priority_queue_os_executor = typedef threads::executors::local_priority_queue_os_executor
Creates a new local_priority_queue_executor
- Parameters
max_punits
: [in] The maximum number of processing units to associate with the newly created executor.min_punits
: [in] The minimum number of processing units to associate with the newly created executor (default: 1).
-
using
-
namespace
-
namespace
#include <hpx/parallel/executors/guided_chunk_size.hpp>
¶
-
namespace
hpx
-
namespace
parallel
-
namespace
execution
-
struct
guided_chunk_size
¶ - #include <guided_chunk_size.hpp>
Iterations are dynamically assigned to threads in blocks as threads request them until no blocks remain to be assigned. Similar to dynamic_chunk_size except that the block size decreases each time a number of loop iterations is given to a thread. The size of the initial block is proportional to number_of_iterations / number_of_cores. Subsequent blocks are proportional to number_of_iterations_remaining / number_of_cores. The optional chunk size parameter defines the minimum block size. The default chunk size is 1.
- Note
- This executor parameters type is equivalent to OpenMP’s GUIDED scheduling directive.
Public Functions
-
guided_chunk_size
(std::size_t min_chunk_size = 1)¶ Construct a guided_chunk_size executor parameters object
- Parameters
min_chunk_size
: [in] The optional minimal chunk size to use as the minimal number of loop iterations to schedule together. The default minimal chunk size is 1.
-
struct
-
namespace
-
namespace
#include <hpx/parallel/executors/this_thread_executors.hpp>
¶
#include <hpx/parallel/executors/fused_bulk_execute.hpp>
¶
#include <hpx/parallel/executors/thread_pool_executors.hpp>
¶
-
namespace
hpx
-
namespace
parallel
-
namespace
execution
Typedefs
-
using
hpx::parallel::execution::local_priority_queue_executor = typedef threads::executors::local_priority_queue_executor
Creates a new local_priority_queue_executor
- Parameters
max_punits
: [in] The maximum number of processing units to associate with the newly created executor.min_punits
: [in] The minimum number of processing units to associate with the newly created executor (default: 1).
-
using
-
namespace
-
namespace
#include <hpx/parallel/executors/timed_executors.hpp>
¶
-
namespace
hpx
-
namespace
parallel
-
namespace
execution
Typedefs
-
using
hpx::parallel::execution::sequenced_timed_executor = typedef timed_executor<execution::sequenced_executor>
-
using
hpx::parallel::execution::parallel_timed_executor = typedef timed_executor<execution::parallel_executor>
-
template <typename BaseExecutor>
structtimed_executor
¶ Public Types
-
typedef hpx::traits::executor_execution_category<base_executor_type>::type
execution_category
¶
-
typedef hpx::traits::executor_parameters_type<base_executor_type>::type
parameters_type
¶
Public Functions
-
timed_executor
(hpx::util::steady_time_point const &abs_time)¶
-
timed_executor
(hpx::util::steady_duration const &rel_time)¶
-
template <typename Executor>
timed_executor
(Executor &&exec, hpx::util::steady_time_point const &abs_time)¶
-
template <typename Executor>
timed_executor
(Executor &&exec, hpx::util::steady_duration const &rel_time)¶
-
template <typename F, typename... Ts>
hpx::util::detail::invoke_deferred_result<F, Ts...>::typesync_execute
(F &&f, Ts&&... ts)¶
-
template <typename F, typename... Ts>
hpx::future<typename hpx::util::detail::invoke_deferred_result<F, Ts...>::type>async_execute
(F &&f, Ts&&... ts)¶
-
template <typename F, typename... Ts>
voidpost
(F &&f, Ts&&... ts)¶
-
typedef hpx::traits::executor_execution_category<base_executor_type>::type
-
using
-
namespace
-
namespace
#include <hpx/parallel/executors/rebind_executor.hpp>
¶
-
namespace
hpx
-
namespace
parallel
-
namespace
execution
-
template <typename ExecutionPolicy, typename Executor, typename Parameters>
structrebind_executor
¶ - #include <rebind_executor.hpp>
Rebind the type of executor used by an execution policy. The execution category of Executor shall not be weaker than that of ExecutionPolicy.
Public Types
-
typedef ExecutionPolicy::template rebind<executor_type, parameters_type>::type
type
¶ The type of the rebound execution policy.
-
typedef ExecutionPolicy::template rebind<executor_type, parameters_type>::type
-
template <typename ExecutionPolicy, typename Executor, typename Parameters>
-
namespace
-
namespace
#include <hpx/parallel/executors/parallel_executor_aggregated.hpp>
¶
-
template <>
template<>
structparallel_policy_executor_aggregated
<hpx::launch>¶ Public Types
-
template<>
usingexecution_category
= parallel_execution_tag¶ Associate the parallel_execution_tag executor tag type as a default with this executor.
-
template<>
usingexecutor_parameters_type
= static_chunk_size¶ Associate the static_chunk_size executor parameters type as a default with this executor.
Public Functions
-
hpx::parallel::execution::parallel_policy_executor_aggregated::parallel_policy_executor_aggregated(hpx::launch l = hpx::launch::async_policy{}, std::size_t spread = 4, std::size_t tasks = std::size_t(-1))
Create a new parallel executor.
-
template<>
-
namespace
hpx
-
namespace
parallel
-
namespace
execution
Typedefs
-
using
hpx::parallel::execution::parallel_executor_aggregated = typedef parallel_policy_executor_aggregated<hpx::launch::async_policy>
-
template <typename Policy = hpx::launch::async_policy>
structparallel_policy_executor_aggregated
¶ - #include <parallel_executor_aggregated.hpp>
A parallel_executor_aggregated creates groups of parallel execution agents that execute in threads implicitly created by the executor. This executor prefers continuing with the creating thread first before executing newly created threads.
This executor conforms to the concepts of a TwoWayExecutor, and a BulkTwoWayExecutor
Public Types
-
template<>
usingexecution_category
= parallel_execution_tag¶ Associate the parallel_execution_tag executor tag type as a default with this executor.
-
template<>
usingexecutor_parameters_type
= static_chunk_size¶ Associate the static_chunk_size executor parameters type as a default with this executor.
-
template<>
-
template <>
template<>
structparallel_policy_executor_aggregated
<hpx::launch> Public Types
-
template<>
usingexecution_category
= parallel_execution_tag Associate the parallel_execution_tag executor tag type as a default with this executor.
-
template<>
usingexecutor_parameters_type
= static_chunk_size Associate the static_chunk_size executor parameters type as a default with this executor.
Public Functions
-
hpx::parallel::execution::parallel_policy_executor_aggregated::parallel_policy_executor_aggregated(hpx::launch l = hpx::launch::async_policy{}, std::size_t spread = 4, std::size_t tasks = std::size_t(-1))
Create a new parallel executor.
-
template<>
-
using
-
namespace
-
namespace
#include <hpx/parallel/executors/thread_execution.hpp>
¶
-
namespace
hpx
-
namespace
threads
Functions
-
template <typename Executor, typename F, typename... Ts>
std::enable_if<hpx::traits::is_threads_executor<Executor>::value, hpx::lcos::future<typename hpx::util::detail::invoke_deferred_result<F, Ts...>::type>>::typeasync_execute
(Executor &&exec, F &&f, Ts&&... ts)¶
-
template <typename Executor, typename F, typename... Ts>
std::enable_if<hpx::traits::is_threads_executor<Executor>::value, typename hpx::util::detail::invoke_deferred_result<F, Ts...>::type>::typesync_execute
(Executor &&exec, F &&f, Ts&&... ts)¶
-
template <typename Executor, typename F, typename Future, typename... Ts>
std::enable_if<hpx::traits::is_threads_executor<Executor>::value, hpx::lcos::future<typename hpx::util::detail::invoke_deferred_result<F, Future, Ts...>::type>>::typethen_execute
(Executor &&exec, F &&f, Future &&predecessor, Ts&&... ts)¶
-
template <typename Executor, typename F, typename... Ts>
std::enable_if<hpx::traits::is_threads_executor<Executor>::value>::typepost
(Executor &&exec, F &&f, Ts&&... ts)¶
-
template <typename Executor, typename F, typename Hint, typename... Ts>
std::enable_if<hpx::traits::is_threads_executor<Executor>::value && std::is_same<typename hpx::util::decay<Hint>::type, hpx::threads::thread_schedule_hint>::value>::typepost
(Executor &&exec, F &&f, Hint &&hint, const char *annotation, Ts&&... ts)¶
-
template <typename Executor, typename F, typename Shape, typename... Ts>
std::enable_if<hpx::traits::is_threads_executor<Executor>::value, std::vector<hpx::lcos::future<typename parallel::execution::detail::bulk_function_result<F, Shape, Ts...>::type>>>::typebulk_async_execute
(Executor &&exec, F &&f, Shape const &shape, Ts&&... ts)¶
-
template <typename Executor, typename F, typename Shape, typename... Ts>
std::enable_if<hpx::traits::is_threads_executor<Executor>::value, typename parallel::execution::detail::bulk_execute_result<F, Shape, Ts...>::type>::typebulk_sync_execute
(Executor &&exec, F &&f, Shape const &shape, Ts&&... ts)¶
-
template <typename Executor, typename F, typename Shape, typename Future, typename... Ts>
std::enable_if<hpx::traits::is_threads_executor<Executor>::value, hpx::future<typename parallel::execution::detail::bulk_then_execute_result<F, Shape, Future, Ts...>::type>>::typebulk_then_execute
(Executor &&exec, F &&f, Shape const &shape, Future &&predecessor, Ts&&... ts)¶
-
template <typename Executor, typename F, typename... Ts>
-
namespace
#include <hpx/parallel/executors/thread_pool_executor.hpp>
¶
-
namespace
hpx
-
namespace
parallel
-
namespace
execution
-
struct
thread_pool_executor
¶ - #include <thread_pool_executor.hpp>
A thread_pool_executor creates groups of parallel execution agents which execute in threads implicitly created by the executor. This executor prefers continuing with the creating thread first before executing newly created threads.
This executor conforms to the concepts of a TwoWayExecutor, and a BulkTwoWayExecutor
Public Types
-
typedef parallel_execution_tag
execution_category
¶ Associate the parallel_execution_tag executor tag type as a default with this executor.
-
typedef static_chunk_size
executor_parameters_type
¶ Associate the static_chunk_size executor parameters type as a default with this executor.
Public Functions
-
thread_pool_executor
(threads::thread_pool_base *pool)¶ Create a new parallel executor.
Private Members
-
threads::thread_pool_base *
pool_
¶
-
typedef parallel_execution_tag
-
struct
-
namespace
-
namespace
#include <hpx/parallel/executors/parallel_executor.hpp>
¶
-
namespace
hpx
-
namespace
parallel
-
namespace
execution
Typedefs
-
using
hpx::parallel::execution::parallel_executor = typedef parallel_policy_executor<hpx::launch>
-
template <typename Policy>
structparallel_policy_executor
¶ - #include <parallel_executor.hpp>
A parallel_executor creates groups of parallel execution agents which execute in threads implicitly created by the executor. This executor prefers continuing with the creating thread first before executing newly created threads.
This executor conforms to the concepts of a TwoWayExecutor, and a BulkTwoWayExecutor
Public Types
-
typedef parallel_execution_tag
execution_category
¶ Associate the parallel_execution_tag executor tag type as a default with this executor.
-
typedef static_chunk_size
executor_parameters_type
¶ Associate the static_chunk_size executor parameters type as a default with this executor.
-
typedef parallel_execution_tag
-
using
-
namespace
-
namespace
#include <hpx/parallel/executors/persistent_auto_chunk_size.hpp>
¶
-
namespace
hpx
-
namespace
parallel
-
namespace
execution
-
struct
persistent_auto_chunk_size
¶ - #include <persistent_auto_chunk_size.hpp>
Loop iterations are divided into pieces and then assigned to threads. The number of loop iterations combined is determined based on measurements of how long the execution of 1% of the overall number of iterations takes. This executor parameters type makes sure that as many loop iterations are combined as necessary to run for the amount of time specified.
Public Functions
-
persistent_auto_chunk_size
()¶ Construct an persistent_auto_chunk_size executor parameters object
- Note
- Default constructed persistent_auto_chunk_size executor parameter types will use 0 microseconds as the execution time for each chunk and 80 microseconds as the minimal time for which any of the scheduled chunks should run.
-
persistent_auto_chunk_size
(hpx::util::steady_duration const &time_cs)¶ Construct an persistent_auto_chunk_size executor parameters object
- Parameters
time_cs
: The execution time for each chunk.
-
persistent_auto_chunk_size
(hpx::util::steady_duration const &time_cs, hpx::util::steady_duration const &rel_time)¶ Construct an persistent_auto_chunk_size executor parameters object
- Parameters
rel_time
: [in] The time duration to use as the minimum to decide how many loop iterations should be combined.time_cs
: The execution time for each chunk.
-
-
struct
-
namespace
-
namespace
#include <hpx/parallel/executors/pool_executor.hpp>
¶
-
namespace
hpx
-
namespace
parallel
-
namespace
execution
Typedefs
-
using
hpx::parallel::execution::pool_executor = typedef threads::executors::pool_executor
-
using
-
namespace
-
namespace
#include <hpx/parallel/executors/post_policy_dispatch.hpp>
¶
#include <hpx/parallel/executors/sequenced_executor.hpp>
¶
-
namespace
hpx
-
namespace
parallel
-
namespace
execution
-
struct
sequenced_executor
¶ - #include <sequenced_executor.hpp>
A sequential_executor creates groups of sequential execution agents which execute in the calling thread. The sequential order is given by the lexicographical order of indices in the index space.
-
struct
-
namespace
-
namespace
#include <hpx/parallel/executors/thread_execution_information.hpp>
¶
-
namespace
hpx
-
namespace
threads
Functions
-
template <typename Executor, typename Parameters>
std::enable_if<hpx::traits::is_threads_executor<Executor>::value, std::size_t>::typeprocessing_units_count
(Executor &&exec, Parameters&)¶
-
template <typename Executor>
std::enable_if<hpx::traits::is_threads_executor<Executor>::value, bool>::typehas_pending_closures
(Executor &&exec)¶
-
template <typename Executor, typename Parameters>
-
namespace
#include <hpx/parallel/executors/execution_fwd.hpp>
¶
-
namespace
hpx
-
namespace
parallel
-
namespace
execution
-
struct
parallel_execution_tag
¶ - #include <execution_fwd.hpp>
Function invocations executed by a group of parallel execution agents execute in unordered fashion. Any such invocations executing in the same thread are indeterminately sequenced with respect to each other.
- Note
- parallel_execution_tag is weaker than sequenced_execution_tag.
-
struct
sequenced_execution_tag
¶ - #include <execution_fwd.hpp>
Function invocations executed by a group of sequential execution agents execute in sequential order.
-
struct
unsequenced_execution_tag
¶ - #include <execution_fwd.hpp>
Function invocations executed by a group of vector execution agents are permitted to execute in unordered fashion when executed in different threads, and un-sequenced with respect to one another when executed in the same thread.
- Note
- unsequenced_execution_tag is weaker than parallel_execution_tag.
-
struct
-
namespace
-
namespace
#include <hpx/parallel/executors/static_chunk_size.hpp>
¶
-
namespace
hpx
-
namespace
parallel
-
namespace
execution
-
struct
static_chunk_size
¶ - #include <static_chunk_size.hpp>
Loop iterations are divided into pieces of size chunk_size and then assigned to threads. If chunk_size is not specified, the iterations are evenly (if possible) divided contiguously among the threads.
- Note
- This executor parameters type is equivalent to OpenMP’s STATIC scheduling directive.
Public Functions
-
static_chunk_size
()¶ Construct a static_chunk_size executor parameters object
- Note
- By default the number of loop iterations is determined from the number of available cores and the overall number of loop iterations to schedule.
-
static_chunk_size
(std::size_t chunk_size)¶ Construct a static_chunk_size executor parameters object
- Parameters
chunk_size
: [in] The optional chunk size to use as the number of loop iterations to run on a single thread.
-
struct
-
namespace
-
namespace
#include <hpx/parallel/executors/execution_information.hpp>
¶
-
namespace
hpx
-
namespace
threads
-
namespace
#include <hpx/parallel/executors/timed_execution.hpp>
¶
#include <hpx/parallel/traits/vector_pack_count_bits.hpp>
¶
-
namespace
hpx
-
namespace
parallel
-
namespace
traits
Functions
-
HPX_HOST_DEVICE std::size_t hpx::parallel::traits::count_bits(bool value)
-
-
namespace
-
namespace