kokkos-execution 0.0.1
Loading...
Searching...
No Matches
Kokkos::Execution::GraphImpl::OpState< Sndr, Rcvr, FirstClosure, RestOfClosures > Struct Template Reference

Operation state that adds all closures as a sequence of nodes. More...

#include <operation_state.hpp>

Inheritance diagram for Kokkos::Execution::GraphImpl::OpState< Sndr, Rcvr, FirstClosure, RestOfClosures >:
Kokkos::Execution::Impl::Immovable Kokkos::Execution::GraphImpl::OpStateBase< FirstClosure::execution_space, Rcvr >

Public Types

using operation_state_concept = stdexec::operation_state_tag
using execution_space = typename FirstClosure::execution_space
using device_handle_t = typename FirstClosure::device_handle_t
using rcvr_t = Impl::Receiver<OpState, stdexec::env_of_t<Rcvr>>
 Ensure that all closures are on the same execution space type.
using inner_opstate_t = stdexec::connect_result_t<Sndr, rcvr_t>
using graph_composition_policy_t = GraphComposition::policy_t<inner_opstate_t>
using state_t = State<graph_composition_policy_t, execution_space>
using predecessor_t = GraphComposition::node_t<execution_space, inner_opstate_t>
using node_t
Public Types inherited from Kokkos::Execution::GraphImpl::OpStateBase< FirstClosure::execution_space, Rcvr >
using sync_policy_t
using completion_signal_t

Public Member Functions

constexpr OpState (Sndr &&sndr, Rcvr rcvr, FirstClosure clsr, RestOfClosures... clsrs) noexcept(false)
predecessor_t get_predecessor () const
void complete (stdexec::set_value_t) noexcept
const auto & query (get_node_t) const &noexcept
const auto & query (get_graph_t) const &noexcept
void start () &noexcept
constexpr auto get_env () const noexcept -> stdexec::env_of_t< Rcvr >
Public Member Functions inherited from Kokkos::Execution::Impl::Immovable
 Immovable ()=default
 Immovable (Immovable &&)=delete
Immovableoperator= (Immovable &&)=delete
 Immovable (const Immovable &)=delete
Immovableoperator= (const Immovable &)=delete
 ~Immovable ()=default
Public Member Functions inherited from Kokkos::Execution::GraphImpl::OpStateBase< FirstClosure::execution_space, Rcvr >
constexpr OpStateBase (Rcvr rcvr) noexcept(std::is_nothrow_constructible_v< completion_signal_t, Rcvr && >)
void complete (stdexec::set_value_t) noexcept

Public Attributes

inner_opstate_t inner_opstate
state_t state
node_t node
Public Attributes inherited from Kokkos::Execution::GraphImpl::OpStateBase< FirstClosure::execution_space, Rcvr >
completion_signal_t completion_signal

Static Public Attributes

static constexpr bool after_root = std::same_as<graph_composition_policy_t, GraphComposition::Create>

Detailed Description

template<stdexec::sender Sndr, stdexec::receiver Rcvr, Closure FirstClosure, Closure... RestOfClosures>
struct Kokkos::Execution::GraphImpl::OpState< Sndr, Rcvr, FirstClosure, RestOfClosures >

Operation state that adds all closures as a sequence of nodes.

Definition at line 107 of file operation_state.hpp.

Member Typedef Documentation

◆ device_handle_t

template<stdexec::sender Sndr, stdexec::receiver Rcvr, Closure FirstClosure, Closure... RestOfClosures>
using Kokkos::Execution::GraphImpl::OpState< Sndr, Rcvr, FirstClosure, RestOfClosures >::device_handle_t = typename FirstClosure::device_handle_t

Definition at line 113 of file operation_state.hpp.

◆ execution_space

template<stdexec::sender Sndr, stdexec::receiver Rcvr, Closure FirstClosure, Closure... RestOfClosures>
using Kokkos::Execution::GraphImpl::OpState< Sndr, Rcvr, FirstClosure, RestOfClosures >::execution_space = typename FirstClosure::execution_space

Definition at line 112 of file operation_state.hpp.

◆ graph_composition_policy_t

template<stdexec::sender Sndr, stdexec::receiver Rcvr, Closure FirstClosure, Closure... RestOfClosures>
using Kokkos::Execution::GraphImpl::OpState< Sndr, Rcvr, FirstClosure, RestOfClosures >::graph_composition_policy_t = GraphComposition::policy_t<inner_opstate_t>

Definition at line 120 of file operation_state.hpp.

◆ inner_opstate_t

template<stdexec::sender Sndr, stdexec::receiver Rcvr, Closure FirstClosure, Closure... RestOfClosures>
using Kokkos::Execution::GraphImpl::OpState< Sndr, Rcvr, FirstClosure, RestOfClosures >::inner_opstate_t = stdexec::connect_result_t<Sndr, rcvr_t>

Definition at line 119 of file operation_state.hpp.

◆ node_t

template<stdexec::sender Sndr, stdexec::receiver Rcvr, Closure FirstClosure, Closure... RestOfClosures>
using Kokkos::Execution::GraphImpl::OpState< Sndr, Rcvr, FirstClosure, RestOfClosures >::node_t
Initial value:
decltype(add_nodes(
std::declval<predecessor_t>(),
std::declval<FirstClosure>(),
std::declval<RestOfClosures>()...))
static auto add_nodes(Predecessor &&predecessor, FirstClosure &&clsr, RestOfClosures &&... clsrs)
Add all nodes as a sequence. Hence, only the first node may be added after the root node.

Definition at line 126 of file operation_state.hpp.

◆ operation_state_concept

template<stdexec::sender Sndr, stdexec::receiver Rcvr, Closure FirstClosure, Closure... RestOfClosures>
using Kokkos::Execution::GraphImpl::OpState< Sndr, Rcvr, FirstClosure, RestOfClosures >::operation_state_concept = stdexec::operation_state_tag

Definition at line 110 of file operation_state.hpp.

◆ predecessor_t

template<stdexec::sender Sndr, stdexec::receiver Rcvr, Closure FirstClosure, Closure... RestOfClosures>
using Kokkos::Execution::GraphImpl::OpState< Sndr, Rcvr, FirstClosure, RestOfClosures >::predecessor_t = GraphComposition::node_t<execution_space, inner_opstate_t>

Definition at line 122 of file operation_state.hpp.

◆ rcvr_t

template<stdexec::sender Sndr, stdexec::receiver Rcvr, Closure FirstClosure, Closure... RestOfClosures>
using Kokkos::Execution::GraphImpl::OpState< Sndr, Rcvr, FirstClosure, RestOfClosures >::rcvr_t = Impl::Receiver<OpState, stdexec::env_of_t<Rcvr>>

Ensure that all closures are on the same execution space type.

Definition at line 118 of file operation_state.hpp.

◆ state_t

template<stdexec::sender Sndr, stdexec::receiver Rcvr, Closure FirstClosure, Closure... RestOfClosures>
using Kokkos::Execution::GraphImpl::OpState< Sndr, Rcvr, FirstClosure, RestOfClosures >::state_t = State<graph_composition_policy_t, execution_space>

Definition at line 121 of file operation_state.hpp.

Constructor & Destructor Documentation

◆ OpState()

template<stdexec::sender Sndr, stdexec::receiver Rcvr, Closure FirstClosure, Closure... RestOfClosures>
Kokkos::Execution::GraphImpl::OpState< Sndr, Rcvr, FirstClosure, RestOfClosures >::OpState ( Sndr && sndr,
Rcvr rcvr,
FirstClosure clsr,
RestOfClosures... clsrs )
inlineconstexpr
Warning
Unconditionally not noexcept because both graph and node construction may throw.

Definition at line 136 of file operation_state.hpp.

References Kokkos::Execution::GraphImpl::add_nodes(), get_predecessor(), inner_opstate, node, Kokkos::Execution::GraphImpl::OpStateBase< FirstClosure::execution_space, Rcvr >::OpStateBase(), and state.

Member Function Documentation

◆ complete()

template<stdexec::sender Sndr, stdexec::receiver Rcvr, Closure FirstClosure, Closure... RestOfClosures>
void Kokkos::Execution::GraphImpl::OpState< Sndr, Rcvr, FirstClosure, RestOfClosures >::complete ( stdexec::set_value_t )
inlinenoexcept

◆ get_env()

template<stdexec::sender Sndr, stdexec::receiver Rcvr, Closure FirstClosure, Closure... RestOfClosures>
auto Kokkos::Execution::GraphImpl::OpState< Sndr, Rcvr, FirstClosure, RestOfClosures >::get_env ( ) const->stdexec::env_of_t< Rcvr >
inlinenodiscardconstexprnoexcept

◆ get_predecessor()

template<stdexec::sender Sndr, stdexec::receiver Rcvr, Closure FirstClosure, Closure... RestOfClosures>
predecessor_t Kokkos::Execution::GraphImpl::OpState< Sndr, Rcvr, FirstClosure, RestOfClosures >::get_predecessor ( ) const
inline

If the graph composition policy is GraphComposition::Create, return the root node of state graph. Otherwise, return the result of querying inner_opstate for get_node_t.

Definition at line 157 of file operation_state.hpp.

References after_root, Kokkos::Execution::GraphImpl::get_graph_impl_ptr(), Kokkos::Execution::GraphImpl::get_node, Kokkos::Execution::GraphImpl::get_node_ptr(), inner_opstate, and state.

◆ query() [1/2]

template<stdexec::sender Sndr, stdexec::receiver Rcvr, Closure FirstClosure, Closure... RestOfClosures>
const auto & Kokkos::Execution::GraphImpl::OpState< Sndr, Rcvr, FirstClosure, RestOfClosures >::query ( get_graph_t ) const &
inlinenoexcept

◆ query() [2/2]

template<stdexec::sender Sndr, stdexec::receiver Rcvr, Closure FirstClosure, Closure... RestOfClosures>
const auto & Kokkos::Execution::GraphImpl::OpState< Sndr, Rcvr, FirstClosure, RestOfClosures >::query ( get_node_t ) const &
inlinenoexcept

Definition at line 187 of file operation_state.hpp.

References node.

◆ start()

template<stdexec::sender Sndr, stdexec::receiver Rcvr, Closure FirstClosure, Closure... RestOfClosures>
void Kokkos::Execution::GraphImpl::OpState< Sndr, Rcvr, FirstClosure, RestOfClosures >::start ( ) &
inlinenoexcept

Definition at line 199 of file operation_state.hpp.

References inner_opstate.

Member Data Documentation

◆ after_root

template<stdexec::sender Sndr, stdexec::receiver Rcvr, Closure FirstClosure, Closure... RestOfClosures>
bool Kokkos::Execution::GraphImpl::OpState< Sndr, Rcvr, FirstClosure, RestOfClosures >::after_root = std::same_as<graph_composition_policy_t, GraphComposition::Create>
staticconstexpr

Definition at line 124 of file operation_state.hpp.

◆ inner_opstate

template<stdexec::sender Sndr, stdexec::receiver Rcvr, Closure FirstClosure, Closure... RestOfClosures>
inner_opstate_t Kokkos::Execution::GraphImpl::OpState< Sndr, Rcvr, FirstClosure, RestOfClosures >::inner_opstate

Definition at line 131 of file operation_state.hpp.

◆ node

template<stdexec::sender Sndr, stdexec::receiver Rcvr, Closure FirstClosure, Closure... RestOfClosures>
node_t Kokkos::Execution::GraphImpl::OpState< Sndr, Rcvr, FirstClosure, RestOfClosures >::node

Definition at line 133 of file operation_state.hpp.

◆ state

template<stdexec::sender Sndr, stdexec::receiver Rcvr, Closure FirstClosure, Closure... RestOfClosures>
state_t Kokkos::Execution::GraphImpl::OpState< Sndr, Rcvr, FirstClosure, RestOfClosures >::state

Definition at line 132 of file operation_state.hpp.


The documentation for this struct was generated from the following file: