|
dune-common 2.10
|
Loading...
Searching...
No Matches
layout_stride.hh
Go to the documentation of this file.
3// SPDX-FileCopyrightInfo: Copyright © DUNE Project contributors, see file LICENSE.md in module root
123 return extents_type::rank() == 0 || (required_span_size() > 0 && required_span_size() == extents().product());
decltype(auto) constexpr unpackIntegerSequence(F &&f, std::integer_sequence< I, i... > sequence)
Unpack an std::integer_sequence<I,i...> to std::integral_constant<I,i>...
Definition indices.hh:124
Multidimensional index space with dynamic and static extents.
Definition extents.hh:54
constexpr index_type extent(rank_type r) const noexcept
Return the extent of dimension i
Definition extents.hh:100
A layout where the rightmost extent has stride 1, and strides increase right-to-left as the product o...
Definition fwd_layouts.hh:30
A layout mapping where the strides are user-defined.
Definition fwd_layouts.hh:40
A layout mapping where the strides are user-defined.
Definition layout_stride.hh:19
constexpr mapping(const extents_type &e, const span< OtherIndexType, rank_ > &s) noexcept
Construct the mapping from given extents and strides.
Definition layout_stride.hh:59
constexpr mapping & operator=(const mapping &) noexcept=default
Copy-assignment for the mapping.
constexpr bool is_exhaustive() const noexcept
Definition layout_stride.hh:118
constexpr mapping() noexcept
The default construction initializes the strides from layout_right.
Definition layout_stride.hh:36
constexpr mapping(const extents_type &e, const std::array< OtherIndexType, rank_ > &s) noexcept
Construct the mapping from given extents and strides.
Definition layout_stride.hh:47
constexpr index_type stride(rank_type i) const noexcept
Get the single stride i
Definition layout_stride.hh:135
typename extents_type::index_type index_type
Definition layout_stride.hh:25
static constexpr bool is_always_exhaustive() noexcept
Definition layout_stride.hh:112
constexpr const extents_type & extents() const noexcept
Definition layout_stride.hh:85
static constexpr bool is_strided() noexcept
Definition layout_stride.hh:116
static constexpr bool is_always_strided() noexcept
Definition layout_stride.hh:113
constexpr index_type required_span_size() const noexcept
Return the sum 1 + (E(0)-1)*S(0) + (E(1)-1)*S(1) + ...
Definition layout_stride.hh:88
constexpr const strides_type & strides() const noexcept
Get the array of all strides.
Definition layout_stride.hh:127
constexpr mapping(const mapping &) noexcept=default
Copy constructor for the mapping.
typename extents_type::rank_type rank_type
Definition layout_stride.hh:27
static constexpr bool is_unique() noexcept
Definition layout_stride.hh:115
constexpr index_type operator()() const noexcept
The default offset for rank-0 tensors is 0.
Definition layout_stride.hh:106
typename extents_type::size_type size_type
Definition layout_stride.hh:26
static constexpr bool is_always_unique() noexcept
Definition layout_stride.hh:111
A contiguous sequence of elements with static or dynamic extent.
Definition span.hh:126
Legal Statements / Impressum | Hosted by TU Dresden & Uni Heidelberg | Generated by
1.9.8