thread_init_data(F && f, util::thread_description const& desc, naming::address_type lva_ = 0, thread_priority priority_ = thread_priority_normal, thread_schedule_hint os_thread = thread_schedule_hint(), std::ptrdiff_t stacksize_ = std::ptrdiff_t(-1), policies::scheduler_base* scheduler_base_ = nullptr) : func(std::forward<F>(f)), #if defined(HPX_HAVE_THREAD_TARGET_ADDRESS) lva(lva_), #endif #if defined(HPX_HAVE_THREAD_DESCRIPTION) description(desc), #endif #if defined(HPX_HAVE_THREAD_PARENT_REFERENCE) parent_locality_id(0), parent_id(nullptr), parent_phase(0), #endif #ifdef HPX_HAVE_APEX /* HPX_HAVE_APEX forces the HPX_HAVE_THREAD_DESCRIPTION * and HPX_HAVE_THREAD_PARENT_REFERENCE settings to be on */ apex_data(apex_new_task(description,parent_locality_id,parent_id)), #endif priority(priority_), schedulehint(os_thread), stacksize(stacksize_ == std::ptrdiff_t(-1) ? get_default_stack_size() : stacksize_), scheduler_base(scheduler_base_) { if (stacksize == 0) stacksize = get_default_stack_size(); }
thread_init_data(thread_init_data&& rhs) : func(std::move(rhs.func)), #if defined(HPX_HAVE_THREAD_TARGET_ADDRESS) lva(rhs.lva), #endif #if defined(HPX_HAVE_THREAD_DESCRIPTION) description(rhs.description), #endif #if defined(HPX_HAVE_THREAD_PARENT_REFERENCE) parent_locality_id(rhs.parent_locality_id), parent_id(rhs.parent_id), parent_phase(rhs.parent_phase), #endif #ifdef HPX_HAVE_APEX /* HPX_HAVE_APEX forces the HPX_HAVE_THREAD_DESCRIPTION * and HPX_HAVE_THREAD_PARENT_REFERENCE settings to be on */ apex_data(apex_new_task(description, parent_locality_id, parent_id )), #endif priority(rhs.priority), schedulehint(rhs.schedulehint), stacksize(rhs.stacksize), scheduler_base(rhs.scheduler_base) { if (stacksize == 0) stacksize = get_default_stack_size(); }
thread_init_data(F && f, util::thread_description const& desc, naming::address_type lva_ = 0, thread_priority priority_ = thread_priority_normal, std::size_t os_thread = std::size_t(-1), std::ptrdiff_t stacksize_ = std::ptrdiff_t(-1), policies::scheduler_base* scheduler_base_ = nullptr) : func(std::forward<F>(f)), #if defined(HPX_HAVE_THREAD_TARGET_ADDRESS) lva(lva_), #endif #if defined(HPX_HAVE_THREAD_DESCRIPTION) description(desc), #endif #if defined(HPX_HAVE_THREAD_PARENT_REFERENCE) parent_locality_id(0), parent_id(nullptr), parent_phase(0), #endif priority(priority_), num_os_thread(os_thread), stacksize(stacksize_ == std::ptrdiff_t(-1) ? get_default_stack_size() : stacksize_), scheduler_base(scheduler_base_) { if (stacksize == 0) stacksize = get_default_stack_size(); }
thread_init_data() : func(), #if defined(HPX_HAVE_THREAD_TARGET_ADDRESS) lva(0), #endif #if defined(HPX_HAVE_THREAD_DESCRIPTION) description(0), #endif #if defined(HPX_HAVE_THREAD_PARENT_REFERENCE) parent_locality_id(0), parent_id(0), parent_phase(0), #endif priority(thread_priority_normal), num_os_thread(std::size_t(-1)), stacksize(get_default_stack_size()), scheduler_base(0) {}
thread_init_data() : func(), #if defined(HPX_HAVE_THREAD_TARGET_ADDRESS) lva(0), #endif #if defined(HPX_HAVE_THREAD_DESCRIPTION) description(), #endif #if defined(HPX_HAVE_THREAD_PARENT_REFERENCE) parent_locality_id(0), parent_id(nullptr), parent_phase(0), #endif #ifdef HPX_HAVE_APEX apex_data(nullptr), #endif priority(thread_priority_normal), schedulehint(), stacksize(get_default_stack_size()), scheduler_base(nullptr) {}
thread_init_data(thread_init_data&& rhs) : func(std::move(rhs.func)), #if defined(HPX_HAVE_THREAD_TARGET_ADDRESS) lva(rhs.lva), #endif #if defined(HPX_HAVE_THREAD_DESCRIPTION) description(rhs.description), #endif #if defined(HPX_HAVE_THREAD_PARENT_REFERENCE) parent_locality_id(rhs.parent_locality_id), parent_id(rhs.parent_id), parent_phase(rhs.parent_phase), #endif priority(rhs.priority), num_os_thread(rhs.num_os_thread), stacksize(rhs.stacksize), scheduler_base(rhs.scheduler_base) { if (stacksize == 0) stacksize = get_default_stack_size(); }
thread_init_data(F && f, char const* desc, naming::address::address_type lva_ = 0, thread_priority priority_ = thread_priority_normal, std::size_t os_thread = std::size_t(-1), std::ptrdiff_t stacksize_ = std::ptrdiff_t(-1), naming::id_type const& target_ = naming::invalid_id, policies::scheduler_base* scheduler_base_ = 0) : func(std::forward<F>(f)), #if defined(HPX_THREAD_MAINTAIN_TARGET_ADDRESS) lva(lva_), #endif #if defined(HPX_THREAD_MAINTAIN_DESCRIPTION) description(desc), #endif #if defined(HPX_THREAD_MAINTAIN_PARENT_REFERENCE) parent_locality_id(0), parent_id(0), parent_phase(0), #endif priority(priority_), num_os_thread(os_thread), stacksize(stacksize_ == std::ptrdiff_t(-1) ? get_default_stack_size() : stacksize_), target(target_), scheduler_base(scheduler_base_) {}
std::size_t os_thread = std::size_t(-1), std::ptrdiff_t stacksize_ = std::ptrdiff_t(-1), policies::scheduler_base* scheduler_base_ = 0) : func(boost::forward<F>(f)), #if HPX_THREAD_MAINTAIN_TARGET_ADDRESS lva(lva_), #endif #if HPX_THREAD_MAINTAIN_DESCRIPTION description(desc), #endif #if HPX_THREAD_MAINTAIN_PARENT_REFERENCE parent_locality_id(0), parent_id(0), parent_phase(0), #endif priority(priority_), num_os_thread(os_thread), stacksize(stacksize_ == std::ptrdiff_t(-1) ? get_default_stack_size() : stacksize_), scheduler_base(scheduler_base_) {} HPX_STD_FUNCTION<threads::thread_function_type> func; #if HPX_THREAD_MAINTAIN_TARGET_ADDRESS naming::address::address_type lva; #endif #if HPX_THREAD_MAINTAIN_DESCRIPTION char const* description; #endif #if HPX_THREAD_MAINTAIN_PARENT_REFERENCE boost::uint32_t parent_locality_id; threads::thread_id_type parent_id; std::size_t parent_phase;