![]() |
Low-Level Abstraction of Memory Access
|
#include <Common.hpp>
Public Member Functions | |
template<typename ArrayExtents > | |
constexpr auto | size (const ArrayExtents &extents) -> typename ArrayExtents::value_type |
template<typename ArrayExtents > | |
constexpr auto | operator() (const typename ArrayExtents::Index &ai, const ArrayExtents &extents) const -> typename ArrayExtents::value_type |
Functor that maps an ArrayIndex into linear numbers, where the fast moving index should be the rightmost one, which models how C++ arrays work and is analogous to mdspan's layout_right. E.g. ArrayIndex<3> a; stores 3 indices where a[2] should be incremented in the innermost loop.
Definition at line 45 of file Common.hpp.
|
inlineconstexpr |
ai | Index in the array dimensions. |
extents | Total size of the array dimensions. |
Definition at line 57 of file Common.hpp.
|
inlineconstexpr |
Definition at line 48 of file Common.hpp.