#include "TTL_types.h"
Go to the source code of this file.
Data Structures | |
struct | TTL_layout |
Description of a Tensor layout in memory. More... | |
struct | TTL_tensor< TENSORTYPE > |
A poor mans base class for an a tensor in the passed address space. More... | |
struct | TTL_sub_tensor< TENSORTYPE > |
A tensor plus its reference to its parent tensor. More... | |
struct | TTL_sub_tensor< TENSORTYPE >::Origin |
Macros | |
#define | TTL_SIZEOF(type) |
opencl doesn't like sizeof(void) so for it to be 1 like normal c | |
Functions | |
static TTL_offset_dim | TTL_linearize (const TTL_offset &offset, const TTL_layout &layout) |
Calculate the absolute linear offset in elements, based on a given tensor offset and layout. | |
#define TTL_SIZEOF | ( | type | ) |
opencl doesn't like sizeof(void) so for it to be 1 like normal c
OpenCl will produce error: invalid application of 'sizeof' to a void type
This will need to be expanded with more types - or a different language used!
Definition at line 36 of file TTL_cpp/TTL_tensors.h.
|
inlinestatic |
Calculate the absolute linear offset in elements, based on a given tensor offset and layout.
offset | The 3D offset of the required linear offset. |
layout | The layout of the offset being calculated |
Definition at line 81 of file TTL_cpp/TTL_tensors.h.