|
RAJA
RAJA provides a collection of platform portability abstractions for C++ HPC applications.
|
A view to a sequence of objects. More...
#include <Span.hpp>
Public Types | |
| using | element_type = typename std::iterator_traits< IterType >::value_type |
| using | value_type = camp::decay< element_type > |
| using | size_type = IndexType |
| using | difference_type = std::ptrdiff_t |
| using | reference = element_type & |
| using | const_reference = const element_type & |
| using | iterator = IterType |
| using | const_iterator = IterType |
Public Member Functions | |
| constexpr RAJA_HOST_DEVICE | Span (iterator begin, iterator end) |
| constexpr RAJA_HOST_DEVICE | Span (iterator begin, size_type size) |
| constexpr RAJA_HOST_DEVICE RAJA_INLINE iterator | begin () |
| constexpr RAJA_HOST_DEVICE RAJA_INLINE iterator | end () |
| constexpr RAJA_HOST_DEVICE RAJA_INLINE const_iterator | begin () const |
| constexpr RAJA_HOST_DEVICE RAJA_INLINE const_iterator | end () const |
| constexpr RAJA_HOST_DEVICE RAJA_INLINE const_iterator | cbegin () const |
| constexpr RAJA_HOST_DEVICE RAJA_INLINE const_iterator | cend () const |
| constexpr RAJA_HOST_DEVICE RAJA_INLINE reference | front () const |
| constexpr RAJA_HOST_DEVICE RAJA_INLINE reference | back () const |
| constexpr RAJA_HOST_DEVICE RAJA_INLINE reference | operator[] (size_type i) const |
| constexpr RAJA_HOST_DEVICE RAJA_INLINE iterator | data () const |
| constexpr RAJA_HOST_DEVICE RAJA_INLINE size_type | size () const |
| constexpr RAJA_HOST_DEVICE RAJA_INLINE bool | empty () const |
| constexpr RAJA_HOST_DEVICE RAJA_INLINE Span | first (size_type count) const |
| constexpr RAJA_HOST_DEVICE RAJA_INLINE Span | last (size_type count) const |
| constexpr RAJA_HOST_DEVICE RAJA_INLINE Span | subspan (size_type begin, size_type length) const |
| constexpr RAJA_HOST_DEVICE RAJA_INLINE Span | slice (size_type begin, size_type length) const |
Friends | |
| constexpr RAJA_HOST_DEVICE RAJA_INLINE friend iterator | begin (Span &s) |
| constexpr RAJA_HOST_DEVICE RAJA_INLINE friend iterator | end (Span &s) |
| constexpr RAJA_HOST_DEVICE RAJA_INLINE friend const_iterator | begin (const Span &s) |
| constexpr RAJA_HOST_DEVICE RAJA_INLINE friend const_iterator | end (const Span &s) |
| constexpr RAJA_HOST_DEVICE RAJA_INLINE friend const_iterator | cbegin (const Span &s) |
| constexpr RAJA_HOST_DEVICE RAJA_INLINE friend const_iterator | cend (const Span &s) |
A view to a sequence of objects.
Creates a view or container object given a random access iterator and length. Allows use of container interface functions using iterators. Indices are of the type of the second template parameter.
For example:
// Create a span object for an array of ints Span<int*, int> int_span(int_ptr, int_len); // Use with RAJA sort RAJA::sort<policy>(int_span); // Create a span object another way auto double_span = make_span(double_ptr, double_len); // Use with RAJA scan RAJA::inclusive_scan_inplace<policy>(double_span);
Based on the std::span template. Differs in that it supports: random access instead of contiguous iterators different index types and does not support: compile time extents
| using RAJA::Span< IterType, IndexType >::element_type = typename std::iterator_traits<IterType>::value_type |
| using RAJA::Span< IterType, IndexType >::value_type = camp::decay<element_type> |
| using RAJA::Span< IterType, IndexType >::size_type = IndexType |
| using RAJA::Span< IterType, IndexType >::difference_type = std::ptrdiff_t |
| using RAJA::Span< IterType, IndexType >::reference = element_type& |
| using RAJA::Span< IterType, IndexType >::const_reference = const element_type& |
| using RAJA::Span< IterType, IndexType >::iterator = IterType |
| using RAJA::Span< IterType, IndexType >::const_iterator = IterType |
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |
|
inlineconstexpr |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |