Dune Core Modules (2.8.0)
interface.hh File Reference
User interface of the SIMD abstraction. More...
#include <cassert>
#include <cstddef>
#include <type_traits>
#include <utility>
#include <dune/common/simd/base.hh>
#include <dune/common/typelist.hh>
Go to the source code of this file.
Namespaces | |
namespace | Dune |
Dune namespace. | |
namespace | Dune::Simd |
Namespace for vectorization interface functions used by library developers. | |
Basic interface | |
template<class V > | |
using | Dune::Simd::Scalar = typename Overloads::ScalarType< std::decay_t< V > >::type |
Element type of some SIMD type. More... | |
template<class S , class V > | |
using | Dune::Simd::Rebind = typename Overloads::RebindType< std::decay_t< S >, std::decay_t< V > >::type |
Construct SIMD type with different scalar type. More... | |
template<class V > | |
constexpr std::size_t | Dune::Simd::lanes () |
Number of lanes in a SIMD type. More... | |
template<class V > | |
decltype(auto) | Dune::Simd::lane (std::size_t l, V &&v) |
Extract an element of a SIMD type. More... | |
template<class V , class U > | |
constexpr V | Dune::Simd::implCast (U &&u) |
Cast an expression from one implementation to another. More... | |
template<class V , class S > | |
constexpr V | Dune::Simd::broadcast (S s) |
Broadcast a scalar to a vector explicitly. More... | |
template<class M , class V > | |
V | Dune::Simd::cond (M &&mask, const V &ifTrue, const V &ifFalse) |
Like the ?: operator. More... | |
template<class V > | |
V | Dune::Simd::cond (bool mask, const V &ifTrue, const V &ifFalse) |
Like the ?: operator. More... | |
template<class V > | |
auto | Dune::Simd::max (const V &v1, const V &v2) |
The binary maximum value over two simd objects. More... | |
template<class V > | |
auto | Dune::Simd::min (const V &v1, const V &v2) |
The binary minimum value over two simd objects. More... | |
template<class Mask > | |
bool | Dune::Simd::anyTrue (const Mask &mask) |
Whether any entry is true More... | |
template<class Mask > | |
bool | Dune::Simd::allTrue (const Mask &mask) |
Whether all entries are true More... | |
template<class Mask > | |
bool | Dune::Simd::anyFalse (const Mask &mask) |
Whether any entry is false More... | |
template<class Mask > | |
bool | Dune::Simd::allFalse (const Mask &mask) |
Whether all entries are false More... | |
template<class V > | |
Scalar< V > | Dune::Simd::max (const V &v) |
The horizontal maximum value over all lanes. More... | |
template<class V > | |
Scalar< V > | Dune::Simd::min (const V &v) |
The horizontal minimum value over all lanes. More... | |
template<class V > | |
auto | Dune::Simd::mask (const V &v) |
Convert to mask, analogue of bool(s) for scalars. More... | |
template<class V1 , class V2 > | |
auto | Dune::Simd::maskOr (const V1 &v1, const V2 &v2) |
Logic or of masks. More... | |
template<class V1 , class V2 > | |
auto | Dune::Simd::maskAnd (const V1 &v1, const V2 &v2) |
Logic and of masks. More... | |
Syntactic Sugar | |
Templates and functions in this group provide syntactic sugar, they are implemented using the functionality from SimdInterfaceBase, and are not customizable by implementations. | |
template<class V > | |
using | Dune::Simd::Mask = Rebind< bool, V > |
Mask type type of some SIMD type. More... | |
template<class V > | |
std::size_t | Dune::Simd::lanes (const V &) |
Number of lanes in a SIMD type. More... | |
Detailed Description
User interface of the SIMD abstraction.
This file provides the user interface functions of the SIMD abstraction layer.
This file should never be included by users of the SIMD abstraction. Include <dune/common/simd/simd.hh> instead.
|
Legal Statements / Impressum |
Hosted by TU Dresden |
generated with Hugo v0.111.3
(Nov 12, 23:30, 2024)