HCC
HCC is a single-source, C/C++ compiler for heterogeneous computing. It's optimized with HSA (http://www.hsafoundation.com/).
|
Represents a unique position in N-dimensional space. More...
#include <kalmar_index.h>
Public Types | |
typedef int | value_type |
The element type of index<N>. | |
Public Member Functions | |
index () | |
Default constructor. More... | |
index (const index &other) | |
Copy constructor. More... | |
index (const int components[]) | |
Constructs an index<N> with the coordinate values provided the array of int component values. More... | |
index (int components[]) | |
Constructs an index<N> with the coordinate values provided the array of int component values. More... | |
index & | operator= (const index &other) |
Assigns the component values of "other" to this index<N> object. More... | |
__attribute__ ((annotate("__cxxamp_opencl_index"))) void __cxxamp_opencl_index() | |
index (int i0) | |
Constructs an index<N> with the coordinate values provided by . More... | |
template<typename... _Tp> | |
index (_Tp...__t) | |
Constructs an index<N> with the coordinate values provided by . More... | |
int | operator[] (unsigned int c) const |
Returns the index component value at position c. More... | |
int & | operator[] (unsigned int c) |
Returns the index component value at position c. More... | |
bool | operator== (const index &other) const |
Compares two objects of index<N>. More... | |
bool | operator!= (const index &other) const |
Compares two objects of index<N>. More... | |
index & | operator+= (const index &rhs) |
For a given operator , produces the same effect as (*this) = (*this) rhs; The return value is "*this". More... | |
index & | operator-= (const index &rhs) |
For a given operator , produces the same effect as (*this) = (*this) rhs; The return value is "*this". More... | |
index & | operator*= (const index &__r) |
For a given operator , produces the same effect as (*this) = (*this) rhs; The return value is "*this". More... | |
index & | operator/= (const index &__r) |
For a given operator , produces the same effect as (*this) = (*this) rhs; The return value is "*this". More... | |
index & | operator%= (const index &__r) |
For a given operator , produces the same effect as (*this) = (*this) rhs; The return value is "*this". More... | |
index & | operator+= (int value) |
For a given operator , produces the same effect as (*this) = (*this) value; The return value is "*this". More... | |
index & | operator-= (int value) |
For a given operator , produces the same effect as (*this) = (*this) value; The return value is "*this". More... | |
index & | operator*= (int value) |
For a given operator , produces the same effect as (*this) = (*this) value; The return value is "*this". More... | |
index & | operator/= (int value) |
For a given operator , produces the same effect as (*this) = (*this) value; The return value is "*this". More... | |
index & | operator%= (int value) |
For a given operator , produces the same effect as (*this) = (*this) value; The return value is "*this". More... | |
index & | operator++ () |
For a given operator , produces the same effect as (*this) = (*this) 1;. More... | |
index | operator++ (int) |
For a given operator , produces the same effect as (*this) = (*this) 1;. More... | |
index & | operator-- () |
For a given operator , produces the same effect as (*this) = (*this) 1;. More... | |
index | operator-- (int) |
For a given operator , produces the same effect as (*this) = (*this) 1;. More... | |
Static Public Attributes | |
static const int | rank = N |
A static member of index<N> that contains the rank of this index. | |
Friends | |
template<int T> | |
class | Concurrency::extent |
template<int T> | |
class | hc::extent |
template<int K, typename Q > | |
struct | index_helper |
template<int K, typename Q1 , typename Q2 > | |
struct | amp_helper |
Represents a unique position in N-dimensional space.
N | The dimensionality space into which this index applies. Special constructors are supplied for the cases where , but N can be any integer greater than 0. |
|
inline |
Default constructor.
The value at each dimension is initialized to zero. Thus, "index<3> ix;" initializes the variable to the position (0,0,0).
|
inline |
Copy constructor.
Constructs a new index<N> from the supplied argument "other".
[in] | other | An object of type index<N> from which to initialize this new index. |
|
inlineexplicit |
Constructs an index<N> with the coordinate values provided by .
These are specialized constructors that are only valid when the rank of the index . Invoking a specialized constructor whose argument will result in a compilation error.
[in] | i0 | The component values of the index vector. |
Constructs an index<N> with the coordinate values provided by .
These are specialized constructors that are only valid when the rank of the index . Invoking a specialized constructor whose argument will result in a compilation error.
[in] | i0 | The component values of the index vector. |
|
inlineexplicit |
Constructs an index<N> with the coordinate values provided the array of int component values.
If the coordinate array length N, the behavior is undefined. If the array value is NULL or not a valid pointer, the behavior is undefined.
[in] | components | An array of N int values. |
|
inlineexplicit |
Constructs an index<N> with the coordinate values provided the array of int component values.
If the coordinate array length N, the behavior is undefined. If the array value is NULL or not a valid pointer, the behavior is undefined.
[in] | components | An array of N int values. |
|
inline |
Compares two objects of index<N>.
The expression is true if for every i from 0 to N-1.
[in] | other | The right-hand index<N> to be compared. |
|
inline |
For a given operator , produces the same effect as (*this) = (*this) rhs; The return value is "*this".
[in] | rhs | The right-hand index<N> of the arithmetic operation. |
|
inline |
For a given operator , produces the same effect as (*this) = (*this) value; The return value is "*this".
[in] | value | The right-hand int of the arithmetic operation. |
|
inline |
For a given operator , produces the same effect as (*this) = (*this) rhs; The return value is "*this".
[in] | rhs | The right-hand index<N> of the arithmetic operation. |
|
inline |
For a given operator , produces the same effect as (*this) = (*this) value; The return value is "*this".
[in] | value | The right-hand int of the arithmetic operation. |
|
inline |
For a given operator , produces the same effect as (*this) = (*this) 1;.
For prefix increment and decrement, the return value is "*this". Otherwise a new index<N> is returned.
|
inline |
For a given operator , produces the same effect as (*this) = (*this) 1;.
For prefix increment and decrement, the return value is "*this". Otherwise a new index<N> is returned.
|
inline |
For a given operator , produces the same effect as (*this) = (*this) rhs; The return value is "*this".
[in] | rhs | The right-hand index<N> of the arithmetic operation. |
|
inline |
For a given operator , produces the same effect as (*this) = (*this) value; The return value is "*this".
[in] | value | The right-hand int of the arithmetic operation. |
|
inline |
For a given operator , produces the same effect as (*this) = (*this) 1;.
For prefix increment and decrement, the return value is "*this". Otherwise a new index<N> is returned.
|
inline |
For a given operator , produces the same effect as (*this) = (*this) 1;.
For prefix increment and decrement, the return value is "*this". Otherwise a new index<N> is returned.
|
inline |
For a given operator , produces the same effect as (*this) = (*this) rhs; The return value is "*this".
[in] | rhs | The right-hand index<N> of the arithmetic operation. |
|
inline |
For a given operator , produces the same effect as (*this) = (*this) value; The return value is "*this".
[in] | value | The right-hand int of the arithmetic operation. |
|
inline |
For a given operator , produces the same effect as (*this) = (*this) rhs; The return value is "*this".
[in] | rhs | The right-hand index<N> of the arithmetic operation. |
|
inline |
For a given operator , produces the same effect as (*this) = (*this) value; The return value is "*this".
[in] | value | The right-hand int of the arithmetic operation. |
|
inline |
Assigns the component values of "other" to this index<N> object.
[in] | other | An object of type index<N> from which to copy into this index. |
|
inline |
Compares two objects of index<N>.
The expression is true if for every i from 0 to N-1.
[in] | other | The right-hand index<N> to be compared. |
|
inline |
Returns the index component value at position c.
[in] | c | The dimension axis whose coordinate is to be accessed. |
|
inline |
Returns the index component value at position c.
[in] | c | The dimension axis whose coordinate is to be accessed. |