1#ifndef KOKKOS_EXECUTION_GRAPH_SCHEDULE_FROM_HPP
2#define KOKKOS_EXECUTION_GRAPH_SCHEDULE_FROM_HPP
18template <stdexec::receiver Rcvr>
26template <Kokkos::ExecutionSpace Exec, stdexec::sender Sndr, stdexec::receiver Rcvr>
44 stdexec::__nothrow_connectable<Sndr&&, rcvr_t>)
51 requires stdexec::__queryable_with<inner_opstate_t, Impl::get_exec_t>
57 stdexec::set_value(std::move(this->
rcvr));
60 template <
typename Error>
61 void complete(stdexec::set_error_t, Error&& error)
noexcept {
62 stdexec::set_error(std::move(this->
rcvr), std::forward<Error>(error));
65 void complete(stdexec::set_stopped_t)
noexcept {
66 stdexec::set_stopped(std::move(this->
rcvr));
76 std::move(this->
rcvr).submitted();
87 stdexec::set_error(std::move(this->
rcvr), std::current_exception());
90 stdexec::set_value(std::move(this->
rcvr));
95template <stdexec::operation_state OpState, Kokkos::ExecutionSpace Exec>
97 stdexec::__is_instance_of<OpState, Kokkos::Execution::GraphImpl::ScheduleFromOpState>
98 && std::same_as<typename OpState::execution_space, Exec>)
99struct GraphOperationStateFor<OpState, Exec> : public std::true_type { };
102template <
typename Exec,
typename Sndr>
110 template <
typename Self,
typename Rcvr>
113 template <
typename Self,
typename Rcvr>
120 template <stdexec::__decays_to<ScheduleFromSender> Self, stdexec::receiver Rcvr>
121 STDEXEC_EXPLICIT_THIS_BEGIN(
122 auto connect)(
this Self&& self, Rcvr rcvr)
124 return {std::forward<Self>(self).sndr, std::move(rcvr)};
126 STDEXEC_EXPLICIT_THIS_END(connect)
135 template <
typename Env, stdexec::sender Sndr>
136 requires stdexec::__sends<stdexec::set_value_t, Sndr, Env>
137 auto operator()(
const Env&, stdexec::schedule_from_t, stdexec::__ignore, Sndr&&
sndr)
const
138 noexcept(std::is_nothrow_constructible_v<ScheduleFromSender<Impl::exec_of_t<Sndr, Env>, Sndr>, Sndr&&>) {
#define KOKKOS_EXECUTION_IMPL_FORWARDING_ATTRIBUTES_GET_ENV(_type_, _obj_)
#define KOKKOS_EXECUTION_COMPL_SIGS_KEEP(_decayed_self_type_, _sndr_type_)
Concept for a sender whose completion scheduler is Kokkos::Execution::GraphImpl::Scheduler.
#define KOKKOS_EXECUTION_GET_ENV(_type_, _obj_)
Retrieve the environment of _obj_. // NOLINTNEXTLINE(cppcoreguidelines-macro-usage).
auto no_graph_scheduler_in_env() noexcept
Show a better compile diagnostic when there is no Kokkos::Execution::GraphImpl::Scheduler found.
std::conditional_t< ScheduleFrom::signals_submitted< InnerOp, Rcvr >, Impl::SubmittedPolicy::OrderOnExec, Impl::SyncPolicy::InlineFenceExec > completion_signal_policy_t
constexpr get_exec_t get_exec
typename ExecOf< Args... >::type exec_of_t
consteval std::string_view dispatch_label() noexcept
View the dispatch label as a std::string_view.
Operation state for stdexec::schedule_from.
void complete(stdexec::set_value_t) noexcept
ScheduleFromOpState(Sndr &&sndr, Rcvr rcvr) noexcept(//NOLINT(cppcoreguidelines-rvalue-reference-param-not-moved) stdexec::__nothrow_connectable< Sndr &&, rcvr_t >)
Impl::Receiver< ScheduleFromOpState, stdexec::env_of_t< Rcvr > > rcvr_t
void complete(stdexec::set_error_t, Error &&error) noexcept
inner_opstate_t inner_opstate
constexpr auto query(Impl::get_exec_t) const noexcept -> decltype(auto)
void submit() noexcept
Transition to another domain.
ScheduleFromOpStateBase< Rcvr > base_t
stdexec::connect_result_t< Sndr, rcvr_t > inner_opstate_t
void submit() noexcept
Stay in the Kokkos::Execution::GraphImpl::Domain.
void complete(stdexec::set_stopped_t) noexcept
Impl::SubmittedOperationStateTag operation_state_concept
Impl::ScheduleFrom::completion_signal_policy_t< inner_opstate_t, Rcvr > completion_signal_policy_t
Sender for stdexec::schedule_from.
static constexpr bool is_nothrow_connectable_v
stdexec::sender_tag sender_concept
ScheduleFromOpState< execution_space, stdexec::__copy_cvref_t< Self, Sndr >, Rcvr > connect_result_t
Receiver for an object parent_op that implements complete.
#define KOKKOS_EXECUTION_IMPL_MEMBER_CVREF_T(_Self_, _member_)
Yields the type of member _member_ as accessed from expression _Self_, preserving the cv and ref qual...