Developer Guide and Reference

Contents

soa1d_container

Template class for "Structure of Arrays" memory layout of a one-dimensional container of Primitives.
#include <sdlt/soa1d_container.h>

Syntax

template<typename PrimitiveT, int AlignD1OnIndexT = 0, class AllocatorT = allocator::default_alloc> class soa1d_container;
Arguments
typename PrimitiveT
The type that each element in the array will store
int AlignD1OnIndexT = 0
[Optional] The index on which the data access will be aligned (useful for stencils)
class AllocatorT = allocator::default_alloc
[Optional] Specify type of allocator to be used.
allocator::default_alloc
is currently the only allocator supported.
Description
Dynamically sized container of Primitive elements with memory layout as a Structure of Arrays internally providing:
  • Dynamic resizing with interface similar to
    std::vector
  • Accessor objects suitable for efficient data access inside SIMD loops
Member
Description
typedef size_t size_type;
Type to use when specifying sizes to methods of the container.
template <typename OffsetT = no_offset> using accessor;
Template alias to an accessor for this container
template <typename OffsetT = no_offset > using const_accessor;
Template alias to an const_accessor for this container