kokkos-execution 0.0.1
Loading...
Searching...
No Matches
Kokkos::Execution::ExecutionSpaceImpl::ExecutionSpaceRef< Exec > Struct Template Reference

Wrap a Kokkos execution space to make it cheap to copy/move in new environments. More...

#include <get_exec.hpp>

Public Member Functions

constexpr ExecutionSpaceRef (const Exec &exec) noexcept
 ExecutionSpaceRef ()=delete
 ExecutionSpaceRef (const ExecutionSpaceRef &) noexcept=default
ExecutionSpaceRefoperator= (const ExecutionSpaceRef &) noexcept=default
 ExecutionSpaceRef (ExecutionSpaceRef &&) noexcept=default
ExecutionSpaceRefoperator= (ExecutionSpaceRef &&) noexcept=default
 ~ExecutionSpaceRef () noexcept=default
const Exec & get () const noexcept
constexpr const ExecutionSpaceRefquery (const get_exec_t &) const noexcept

Public Attributes

Exec const * m_exec_ptr

Friends

constexpr auto operator<=> (const ExecutionSpaceRef &, const ExecutionSpaceRef &) noexcept=default

Detailed Description

template<Kokkos::ExecutionSpace Exec>
struct Kokkos::Execution::ExecutionSpaceImpl::ExecutionSpaceRef< Exec >

Wrap a Kokkos execution space to make it cheap to copy/move in new environments.

Warning
It does not extend the lifetime of the execution space instance (it does not own it).

Inspired by https://github.com/NVIDIA/cccl/blob/cc7c08209ed4b3ef4c80dc17fa1b8507e9d1e51f/libcudacxx/include/cuda/__stream/stream_ref.h.

Definition at line 31 of file get_exec.hpp.

Constructor & Destructor Documentation

◆ ExecutionSpaceRef() [1/4]

template<Kokkos::ExecutionSpace Exec>
Kokkos::Execution::ExecutionSpaceImpl::ExecutionSpaceRef< Exec >::ExecutionSpaceRef ( const Exec & exec)
inlineexplicitconstexprnoexcept

Definition at line 34 of file get_exec.hpp.

◆ ExecutionSpaceRef() [2/4]

template<Kokkos::ExecutionSpace Exec>
Kokkos::Execution::ExecutionSpaceImpl::ExecutionSpaceRef< Exec >::ExecutionSpaceRef ( )
delete

◆ ExecutionSpaceRef() [3/4]

template<Kokkos::ExecutionSpace Exec>
Kokkos::Execution::ExecutionSpaceImpl::ExecutionSpaceRef< Exec >::ExecutionSpaceRef ( const ExecutionSpaceRef< Exec > & )
defaultnoexcept

References ExecutionSpaceRef().

◆ ExecutionSpaceRef() [4/4]

template<Kokkos::ExecutionSpace Exec>
Kokkos::Execution::ExecutionSpaceImpl::ExecutionSpaceRef< Exec >::ExecutionSpaceRef ( ExecutionSpaceRef< Exec > && )
defaultnoexcept

References ExecutionSpaceRef().

◆ ~ExecutionSpaceRef()

template<Kokkos::ExecutionSpace Exec>
Kokkos::Execution::ExecutionSpaceImpl::ExecutionSpaceRef< Exec >::~ExecutionSpaceRef ( )
defaultnoexcept

References ExecutionSpaceRef().

Member Function Documentation

◆ get()

template<Kokkos::ExecutionSpace Exec>
const Exec & Kokkos::Execution::ExecutionSpaceImpl::ExecutionSpaceRef< Exec >::get ( ) const
inlinenoexcept

Definition at line 45 of file get_exec.hpp.

References get(), and m_exec_ptr.

◆ operator=() [1/2]

template<Kokkos::ExecutionSpace Exec>
ExecutionSpaceRef & Kokkos::Execution::ExecutionSpaceImpl::ExecutionSpaceRef< Exec >::operator= ( const ExecutionSpaceRef< Exec > & )
defaultnoexcept

References ExecutionSpaceRef().

◆ operator=() [2/2]

template<Kokkos::ExecutionSpace Exec>
ExecutionSpaceRef & Kokkos::Execution::ExecutionSpaceImpl::ExecutionSpaceRef< Exec >::operator= ( ExecutionSpaceRef< Exec > && )
defaultnoexcept

References ExecutionSpaceRef().

◆ query()

template<Kokkos::ExecutionSpace Exec>
const ExecutionSpaceRef & Kokkos::Execution::ExecutionSpaceImpl::ExecutionSpaceRef< Exec >::query ( const get_exec_t & ) const
inlinenodiscardconstexprnoexcept

Definition at line 52 of file get_exec.hpp.

References ExecutionSpaceRef().

◆ operator<=>

template<Kokkos::ExecutionSpace Exec>
auto operator<=> ( const ExecutionSpaceRef< Exec > & ,
const ExecutionSpaceRef< Exec > &  )
friend

References ExecutionSpaceRef().

Member Data Documentation

◆ m_exec_ptr

template<Kokkos::ExecutionSpace Exec>
Exec const* Kokkos::Execution::ExecutionSpaceImpl::ExecutionSpaceRef< Exec >::m_exec_ptr

Definition at line 32 of file get_exec.hpp.


The documentation for this struct was generated from the following file:
  • /__w/kokkos-execution/kokkos-execution/kokkos-execution/execution_space/get_exec.hpp