DPC++ Runtime
Runtime libraries for oneAPI DPC++
sycl::_V1::item< dimensions, with_offset > Class Template Reference

Identifies an instance of the function object executing at each point in a range. More...

#include <sycl/detail/helpers.hpp>

Public Member Functions

 item ()=delete
 
id< dimensions > get_id () const
 
size_t __SYCL_ALWAYS_INLINE get_id (int dimension) const
 
size_t __SYCL_ALWAYS_INLINE operator[] (int dimension) const
 
range< dimensions > get_range () const
 
size_t __SYCL_ALWAYS_INLINE get_range (int dimension) const
 
 operator EnableIfT< dimensions==1, std::size_t > () const
 
template<bool has_offset = with_offset>
detail::enable_if_t< has_offset, id< dimensions > > get_offset () const
 
template<bool has_offset = with_offset>
detail::enable_if_t< has_offset, size_t > __SYCL_ALWAYS_INLINE get_offset (int dimension) const
 
template<bool has_offset = with_offset>
 operator detail::enable_if_t<!has_offset, item< dimensions, true >> () const
 
size_t __SYCL_ALWAYS_INLINE get_linear_id () const
 
 item (const item &rhs)=default
 
 item (item< dimensions, with_offset > &&rhs)=default
 
itemoperator= (const item &rhs)=default
 
itemoperator= (item &&rhs)=default
 
bool operator== (const item &rhs) const
 
bool operator!= (const item &rhs) const
 

Protected Member Functions

template<bool has_offset = with_offset>
 item (detail::enable_if_t< has_offset, const range< dimensions >> &extent, const id< dimensions > &index, const id< dimensions > &offset)
 
template<bool has_offset = with_offset>
 item (detail::enable_if_t<!has_offset, const range< dimensions >> &extent, const id< dimensions > &index)
 

Friends

class detail::Builder
 
template<typename , int , typename >
class detail::RoundedRangeKernel
 
template<typename , int , typename >
class detail::RoundedRangeKernelWithKH
 
template<int Dims>
item< Dims, false > detail::reduction::getDelinearizedItem (range< Dims > Range, id< Dims > Id)
 

Detailed Description

template<int dimensions = 1, bool with_offset = true>
class sycl::_V1::item< dimensions, with_offset >

Identifies an instance of the function object executing at each point in a range.

Definition at line 28 of file helpers.hpp.

Constructor & Destructor Documentation

◆ item() [1/5]

template<int dimensions = 1, bool with_offset = true>
sycl::_V1::item< dimensions, with_offset >::item ( )
delete

◆ item() [2/5]

template<int dimensions = 1, bool with_offset = true>
sycl::_V1::item< dimensions, with_offset >::item ( const item< dimensions, with_offset > &  rhs)
default

◆ item() [3/5]

template<int dimensions = 1, bool with_offset = true>
sycl::_V1::item< dimensions, with_offset >::item ( item< dimensions, with_offset > &&  rhs)
default

◆ item() [4/5]

template<int dimensions = 1, bool with_offset = true>
template<bool has_offset = with_offset>
sycl::_V1::item< dimensions, with_offset >::item ( detail::enable_if_t< has_offset, const range< dimensions >> &  extent,
const id< dimensions > &  index,
const id< dimensions > &  offset 
)
inlineprotected

Definition at line 118 of file item.hpp.

◆ item() [5/5]

template<int dimensions = 1, bool with_offset = true>
template<bool has_offset = with_offset>
sycl::_V1::item< dimensions, with_offset >::item ( detail::enable_if_t<!has_offset, const range< dimensions >> &  extent,
const id< dimensions > &  index 
)
inlineprotected

Definition at line 123 of file item.hpp.

Member Function Documentation

◆ get_id() [1/2]

template<int dimensions = 1, bool with_offset = true>
id<dimensions> sycl::_V1::item< dimensions, with_offset >::get_id ( ) const
inline

Definition at line 53 of file item.hpp.

Referenced by sycl::_V1::detail::ItemToStr(), and sycl::_V1::detail::writeItem().

◆ get_id() [2/2]

template<int dimensions = 1, bool with_offset = true>
size_t __SYCL_ALWAYS_INLINE sycl::_V1::item< dimensions, with_offset >::get_id ( int  dimension) const
inline

Definition at line 55 of file item.hpp.

◆ get_linear_id()

template<int dimensions = 1, bool with_offset = true>
size_t __SYCL_ALWAYS_INLINE sycl::_V1::item< dimensions, with_offset >::get_linear_id ( ) const
inline

Definition at line 98 of file item.hpp.

Referenced by sycl::_V1::__SYCL_TYPE().

◆ get_offset() [1/2]

template<int dimensions = 1, bool with_offset = true>
template<bool has_offset = with_offset>
detail::enable_if_t<has_offset, id<dimensions> > sycl::_V1::item< dimensions, with_offset >::get_offset ( ) const
inline

Definition at line 79 of file item.hpp.

Referenced by sycl::_V1::detail::writeItem().

◆ get_offset() [2/2]

template<int dimensions = 1, bool with_offset = true>
template<bool has_offset = with_offset>
detail::enable_if_t<has_offset, size_t> __SYCL_ALWAYS_INLINE sycl::_V1::item< dimensions, with_offset >::get_offset ( int  dimension) const
inline

Definition at line 86 of file item.hpp.

◆ get_range() [1/2]

template<int dimensions = 1, bool with_offset = true>
range<dimensions> sycl::_V1::item< dimensions, with_offset >::get_range ( ) const
inline

Definition at line 67 of file item.hpp.

Referenced by sycl::_V1::detail::ItemToStr(), and sycl::_V1::detail::writeItem().

◆ get_range() [2/2]

template<int dimensions = 1, bool with_offset = true>
size_t __SYCL_ALWAYS_INLINE sycl::_V1::item< dimensions, with_offset >::get_range ( int  dimension) const
inline

Definition at line 69 of file item.hpp.

◆ operator detail::enable_if_t<!has_offset, item< dimensions, true >>()

template<int dimensions = 1, bool with_offset = true>
template<bool has_offset = with_offset>
sycl::_V1::item< dimensions, with_offset >::operator detail::enable_if_t<!has_offset, item< dimensions, true >> ( ) const
inline

Definition at line 93 of file item.hpp.

◆ operator EnableIfT< dimensions==1, std::size_t >()

template<int dimensions = 1, bool with_offset = true>
sycl::_V1::item< dimensions, with_offset >::operator EnableIfT< dimensions==1, std::size_t > ( ) const
inline

Definition at line 75 of file item.hpp.

◆ operator!=()

template<int dimensions = 1, bool with_offset = true>
bool sycl::_V1::item< dimensions, with_offset >::operator!= ( const item< dimensions, with_offset > &  rhs) const
inline

Definition at line 114 of file item.hpp.

◆ operator=() [1/2]

template<int dimensions = 1, bool with_offset = true>
item& sycl::_V1::item< dimensions, with_offset >::operator= ( const item< dimensions, with_offset > &  rhs)
default

◆ operator=() [2/2]

template<int dimensions = 1, bool with_offset = true>
item& sycl::_V1::item< dimensions, with_offset >::operator= ( item< dimensions, with_offset > &&  rhs)
default

◆ operator==()

template<int dimensions = 1, bool with_offset = true>
bool sycl::_V1::item< dimensions, with_offset >::operator== ( const item< dimensions, with_offset > &  rhs) const
inline

Definition at line 112 of file item.hpp.

◆ operator[]()

template<int dimensions = 1, bool with_offset = true>
size_t __SYCL_ALWAYS_INLINE sycl::_V1::item< dimensions, with_offset >::operator[] ( int  dimension) const
inline

Definition at line 61 of file item.hpp.

Friends And Related Function Documentation

◆ detail::Builder

template<int dimensions = 1, bool with_offset = true>
friend class detail::Builder
friend

Definition at line 127 of file item.hpp.

◆ detail::reduction::getDelinearizedItem

template<int dimensions = 1, bool with_offset = true>
template<int Dims>
item<Dims, false> detail::reduction::getDelinearizedItem ( range< Dims >  Range,
id< Dims >  Id 
)
friend

◆ detail::RoundedRangeKernel

template<int dimensions = 1, bool with_offset = true>
template<typename , int , typename >
friend class detail::RoundedRangeKernel
friend

Definition at line 131 of file item.hpp.

◆ detail::RoundedRangeKernelWithKH

template<int dimensions = 1, bool with_offset = true>
template<typename , int , typename >
friend class detail::RoundedRangeKernelWithKH
friend

Definition at line 133 of file item.hpp.


The documentation for this class was generated from the following files: