39#include "../thread/thread_load.cuh"
40#include "../thread/thread_store.cuh"
41#include "../util_device.cuh"
42#include "../util_namespace.cuh"
44#if (THRUST_VERSION >= 100700)
46 #include <thrust/iterator/iterator_facade.h>
47 #include <thrust/iterator/iterator_traits.h>
119 __host__ __device__ __forceinline__
Reference(ValueType* ptr) : ptr(ptr) {}
122 __device__ __forceinline__ ValueType
operator =(ValueType val)
124 ThreadStore<MODIFIER>(ptr, val);
138#if (THRUST_VERSION >= 100700)
140 typedef typename thrust::detail::iterator_facade_category<
141 thrust::device_system_tag,
142 thrust::random_access_traversal_tag,
157 template <
typename QualifiedValueType>
159 QualifiedValueType* ptr)
187 template <
typename Distance>
195 template <
typename Distance>
203 template <
typename Distance>
211 template <
typename Distance>
221 return ptr - other.ptr;
225 template <
typename Distance>
234 return (ptr == rhs.ptr);
240 return (ptr != rhs.ptr);
A random-access output wrapper for storing array values using a PTX cache-modifier.
__host__ __device__ __forceinline__ reference operator*() const
Indirection.
void pointer
The type of a pointer to an element the iterator can point to.
__host__ __device__ __forceinline__ self_type operator+(Distance n) const
Addition.
__host__ __device__ __forceinline__ self_type & operator-=(Distance n)
Subtraction assignment.
__host__ __device__ __forceinline__ self_type & operator+=(Distance n)
Addition assignment.
friend std::ostream & operator<<(std::ostream &os, const self_type &itr)
ostream operator
__host__ __device__ __forceinline__ CacheModifiedOutputIterator(QualifiedValueType *ptr)
Constructor.
Reference reference
The type of a reference to an element the iterator can point to.
__host__ __device__ __forceinline__ bool operator!=(const self_type &rhs)
Not equal to.
__host__ __device__ __forceinline__ self_type operator-(Distance n) const
Subtraction.
__host__ __device__ __forceinline__ difference_type operator-(self_type other) const
Distance.
CacheModifiedOutputIterator self_type
My own type.
__host__ __device__ __forceinline__ bool operator==(const self_type &rhs)
Equal to.
__host__ __device__ __forceinline__ reference operator[](Distance n) const
Array subscript.
OffsetT difference_type
Type to express the result of subtracting one iterator from another.
__host__ __device__ __forceinline__ self_type operator++()
Prefix increment.
std::random_access_iterator_tag iterator_category
The iterator category.
void value_type
The type of the element the iterator can point to.
__host__ __device__ __forceinline__ self_type operator++(int)
Postfix increment.
CacheStoreModifier
Enumeration of cache modifiers for memory store operations.
Optional outer namespace(s)
OffsetT OffsetT
[in] Total number of input data items
__host__ __device__ __forceinline__ Reference(ValueType *ptr)
Constructor.
__device__ __forceinline__ ValueType operator=(ValueType val)
Assignment.
Removes const and volatile qualifiers from type Tp.