29 Numerics library [numerics]

29.10 Data-parallel types [simd]

29.10.9 Non-member operations [simd.mask.nonmembers]

29.10.9.5 basic_simd_mask reductions [simd.mask.reductions]

template<size_t Bytes, class Abi> constexpr bool all_of(const basic_simd_mask<Bytes, Abi>& k) noexcept;
Returns: true if all boolean elements in k are true, otherwise false.
template<size_t Bytes, class Abi> constexpr bool any_of(const basic_simd_mask<Bytes, Abi>& k) noexcept;
Returns: true if at least one boolean element in k is true, otherwise false.
template<size_t Bytes, class Abi> constexpr bool none_of(const basic_simd_mask<Bytes, Abi>& k) noexcept;
Returns: !any_of(k).
template<size_t Bytes, class Abi> constexpr simd-size-type reduce_count(const basic_simd_mask<Bytes, Abi>& k) noexcept;
Returns: The number of boolean elements in k that are true.
template<size_t Bytes, class Abi> constexpr simd-size-type reduce_min_index(const basic_simd_mask<Bytes, Abi>& k);
Preconditions: any_of(k) is true.
Returns: The lowest element index i where k[i] is true.
template<size_t Bytes, class Abi> constexpr simd-size-type reduce_max_index(const basic_simd_mask<Bytes, Abi>& k);
Preconditions: any_of(k) is true.
Returns: The greatest element index i where k[i] is true.
constexpr bool all_of(same_as<bool> auto x) noexcept; constexpr bool any_of(same_as<bool> auto x) noexcept; constexpr simd-size-type reduce_count(same_as<bool> auto x) noexcept;
Returns: x.
constexpr bool none_of(same_as<bool> auto x) noexcept;
Returns: !x.
constexpr simd-size-type reduce_min_index(same_as<bool> auto x); constexpr simd-size-type reduce_max_index(same_as<bool> auto x);
Preconditions: x is true.
Returns: 0.