E.V.E
v2023.02.15
 
Loading...
Searching...
No Matches

◆ logical_not

eve::logical_not = functor<logical_not_t>
inlineconstexpr

Header file

#include <eve/module/core.hpp>

Callable Signatures

namespace eve
{
constexpr auto logical_not(auto logical_value x) noexcept;
}
The concept logical_value<T> is satisfied if and only if T satisfies eve::value and the element type ...
Definition value.hpp:134
constexpr auto logical_not
Computes the logical NOT of its argument.
Definition logical_not.hpp:74
typename decltype(detail::as_translated_type(as< T >{}))::type translate_t
Returns the final translated type of T.
Definition translation.hpp:107
EVE Main Namespace.
Definition abi.hpp:19

Parameters

Return value

The call logical_not(x) is semantically equivalent to is_eqz(x). Infix notation can be used with !x.

Note
Although the infix notation with ! is supported, the ! operator on standard scalar types is the original one and so will return bool instead of eve::logical_value.

Example

// revision 0
#include <eve/module/core.hpp>
#include <iostream>
int main()
{
eve::wide wu0{0u, 1u, 2u, 3u, 4u, 5u, 6u, 7u};
std::cout << "<- wu0 = " << wu0 << "\n";
std::cout << "-> logical_not(wu0 <= maximum(wu0)/2) = " << eve::logical_not(wu0 <= eve::maximum(wu0)/2) << "\n";
}
constexpr auto maximum
Computes the maximal value in a simd vector or valmin if the input is fully masked.
Definition maximum.hpp:82
Wrapper for SIMD registers.
Definition wide.hpp:94