Low-Level Abstraction of Memory Access
llama::mapping::AoS< TArrayExtents, TRecordDim, TFieldAlignment, TLinearizeArrayIndexFunctor, PermuteFields > Struct Template Reference

#include <AoS.hpp>

+ Inheritance diagram for llama::mapping::AoS< TArrayExtents, TRecordDim, TFieldAlignment, TLinearizeArrayIndexFunctor, PermuteFields >:
+ Collaboration diagram for llama::mapping::AoS< TArrayExtents, TRecordDim, TFieldAlignment, TLinearizeArrayIndexFunctor, PermuteFields >:

Public Types

using LinearizeArrayIndexFunctor = TLinearizeArrayIndexFunctor
 
using Permuter = PermuteFields< FlatRecordDim< TRecordDim > >
 
- Public Types inherited from llama::mapping::MappingBase< TArrayExtents, TRecordDim >
using ArrayExtents = TArrayExtents
 
using RecordDim = TRecordDim
 

Public Member Functions

constexpr auto blobSize (size_type) const -> size_type
 
template<std::size_t... RecordCoords>
constexpr auto blobNrAndOffset (typename Base::ArrayIndex ai, RecordCoord< RecordCoords... >={}) const -> NrAndOffset< size_type >
 
- Public Member Functions inherited from llama::mapping::MappingBase< TArrayExtents, TRecordDim >
constexpr MappingBase ()=default
 
constexpr MappingBase (ArrayExtents extents, RecordDim={})
 
constexpr auto extents () const -> ArrayExtents
 

Static Public Attributes

static constexpr FieldAlignment fieldAlignment = TFieldAlignment
 
static constexpr std::size_t blobCount = 1
 

Additional Inherited Members

- Protected Types inherited from llama::mapping::MappingBase< TArrayExtents, TRecordDim >
using ArrayIndex = typename ArrayExtents::Index
 
using size_type = typename ArrayExtents::value_type
 

Detailed Description

template<typename TArrayExtents, typename TRecordDim, FieldAlignment TFieldAlignment = FieldAlignment::Align, typename TLinearizeArrayIndexFunctor = LinearizeArrayIndexRight, template< typename > typename PermuteFields = PermuteFieldsInOrder>
struct llama::mapping::AoS< TArrayExtents, TRecordDim, TFieldAlignment, TLinearizeArrayIndexFunctor, PermuteFields >

Array of struct mapping. Used to create a View via allocView.

Template Parameters
TFieldAlignmentIf Align, padding bytes are inserted to guarantee that struct members are properly aligned. If Pack, struct members are tightly packed.
TLinearizeArrayIndexFunctorDefines how the array dimensions should be mapped into linear numbers and how big the linear domain gets.
PermuteFieldsDefines how the record dimension's fields should be permuted. See PermuteFieldsInOrder, PermuteFieldsIncreasingAlignment, PermuteFieldsDecreasingAlignment and PermuteFieldsMinimizePadding.

Definition at line 25 of file AoS.hpp.

Member Typedef Documentation

◆ LinearizeArrayIndexFunctor

template<typename TArrayExtents , typename TRecordDim , FieldAlignment TFieldAlignment = FieldAlignment::Align, typename TLinearizeArrayIndexFunctor = LinearizeArrayIndexRight, template< typename > typename PermuteFields = PermuteFieldsInOrder>
using llama::mapping::AoS< TArrayExtents, TRecordDim, TFieldAlignment, TLinearizeArrayIndexFunctor, PermuteFields >::LinearizeArrayIndexFunctor = TLinearizeArrayIndexFunctor

Definition at line 33 of file AoS.hpp.

◆ Permuter

template<typename TArrayExtents , typename TRecordDim , FieldAlignment TFieldAlignment = FieldAlignment::Align, typename TLinearizeArrayIndexFunctor = LinearizeArrayIndexRight, template< typename > typename PermuteFields = PermuteFieldsInOrder>
using llama::mapping::AoS< TArrayExtents, TRecordDim, TFieldAlignment, TLinearizeArrayIndexFunctor, PermuteFields >::Permuter = PermuteFields<FlatRecordDim<TRecordDim> >

Definition at line 34 of file AoS.hpp.

Member Function Documentation

◆ blobNrAndOffset()

template<typename TArrayExtents , typename TRecordDim , FieldAlignment TFieldAlignment = FieldAlignment::Align, typename TLinearizeArrayIndexFunctor = LinearizeArrayIndexRight, template< typename > typename PermuteFields = PermuteFieldsInOrder>
template<std::size_t... RecordCoords>
constexpr auto llama::mapping::AoS< TArrayExtents, TRecordDim, TFieldAlignment, TLinearizeArrayIndexFunctor, PermuteFields >::blobNrAndOffset ( typename Base::ArrayIndex  ai,
RecordCoord< RecordCoords... >  = {} 
) const -> NrAndOffset<size_type>
inlineconstexpr

Definition at line 46 of file AoS.hpp.

◆ blobSize()

template<typename TArrayExtents , typename TRecordDim , FieldAlignment TFieldAlignment = FieldAlignment::Align, typename TLinearizeArrayIndexFunctor = LinearizeArrayIndexRight, template< typename > typename PermuteFields = PermuteFieldsInOrder>
constexpr auto llama::mapping::AoS< TArrayExtents, TRecordDim, TFieldAlignment, TLinearizeArrayIndexFunctor, PermuteFields >::blobSize ( size_type  ) const -> size_type
inlineconstexpr

Definition at line 39 of file AoS.hpp.

Member Data Documentation

◆ blobCount

template<typename TArrayExtents , typename TRecordDim , FieldAlignment TFieldAlignment = FieldAlignment::Align, typename TLinearizeArrayIndexFunctor = LinearizeArrayIndexRight, template< typename > typename PermuteFields = PermuteFieldsInOrder>
constexpr std::size_t llama::mapping::AoS< TArrayExtents, TRecordDim, TFieldAlignment, TLinearizeArrayIndexFunctor, PermuteFields >::blobCount = 1
inlinestaticconstexpr

Definition at line 35 of file AoS.hpp.

◆ fieldAlignment

template<typename TArrayExtents , typename TRecordDim , FieldAlignment TFieldAlignment = FieldAlignment::Align, typename TLinearizeArrayIndexFunctor = LinearizeArrayIndexRight, template< typename > typename PermuteFields = PermuteFieldsInOrder>
constexpr FieldAlignment llama::mapping::AoS< TArrayExtents, TRecordDim, TFieldAlignment, TLinearizeArrayIndexFunctor, PermuteFields >::fieldAlignment = TFieldAlignment
inlinestaticconstexpr

Definition at line 32 of file AoS.hpp.


The documentation for this struct was generated from the following file: