native 0.0.1
Vectors, masks and wide register packs for C++26
Loading...
Searching...
No Matches
native::isa< x86 > Struct Reference

Exact X86 feature requirements; construction does not add prerequisites. More...

#include <isa.h>

Public Types

using feature_type = typename detail::feature_traits<x86>::type
 Feature enum accepted by this ISA family.

Public Member Functions

constexpr isa () noexcept=default
 Construct the empty requirement set.
constexpr isa (feature_type f) noexcept
 Require exactly one feature of this family, without prerequisite closure.
constexpr bool get (feature_type f) const noexcept
 Read one feature; out-of-range values are absent.
constexpr void set (feature_type f, bool value) noexcept
constexpr bool has (feature_type f) const noexcept
 True when the feature is present.
constexpr bool has (isa other) const noexcept
 True when every bit in a same-family requirement is present.
constexpr bool valid () const noexcept
 True when no invalid marker or unregistered padding bit is set.
constexpr bool operator== (isa const &) const =default
 Compare every stored bit, including invalid requirements.

Public Attributes

std::array< std::uint64_t,(feature_count+1+63)/64 > flags {}
 Public structural bits; invalid enum values and padding fail validation.
bool mmx
 Read or update the mmx feature bit through flags.
bool sse
 Read or update the sse feature bit through flags.
bool sse2
 Read or update the sse2 feature bit through flags.
bool sse3
 Read or update the sse3 feature bit through flags.
bool ssse3
 Read or update the ssse3 feature bit through flags.
bool sse41
 Read or update the sse41 feature bit through flags.
bool sse42
 Read or update the sse42 feature bit through flags.
bool popcnt
 Read or update the popcnt feature bit through flags.
bool avx
 Read or update the avx feature bit through flags.
bool avx2
 Read or update the avx2 feature bit through flags.
bool fma
 Read or update the fma feature bit through flags.
bool f16c
 Read or update the f16c feature bit through flags.
bool bmi1
 Read or update the bmi1 feature bit through flags.
bool bmi2
 Read or update the bmi2 feature bit through flags.
bool avx512f
 Read or update the avx512f feature bit through flags.
bool avx512dq
 Read or update the avx512dq feature bit through flags.
bool avx512bw
 Read or update the avx512bw feature bit through flags.
bool avx512vl
 Read or update the avx512vl feature bit through flags.
bool avx512bf16
 Read or update the avx512bf16 feature bit through flags.
bool avx512fp16
 Read or update the avx512fp16 feature bit through flags.
bool aes
 Read or update the aes feature bit through flags.
bool pclmul
 Read or update the pclmul feature bit through flags.
bool cx16
 Read or update the cx16 feature bit through flags.
bool avx512cd
 Read or update the avx512cd feature bit through flags.
bool avx512ifma
 Read or update the avx512ifma feature bit through flags.
bool lzcnt
 Read or update the lzcnt feature bit through flags.
bool movbe
 Read or update the movbe feature bit through flags.
bool sahf
 Read or update the sahf feature bit through flags.
bool mwaitx
 Read or update the mwaitx feature bit through flags.
bool waitpkg
 Read or update the waitpkg feature bit through flags.
bool crc32
 Read or update the crc32 feature bit through flags.
bool gfni
 Read or update the gfni feature bit through flags.
bool vpclmulqdq
 Read or update the vpclmulqdq feature bit through flags.
bool avx512vpopcntdq
 Read or update the avx512vpopcntdq feature bit through flags.
bool avxvnni
 Read or update the avxvnni feature bit through flags.
bool avx512vnni
 Read or update the avx512vnni feature bit through flags.
bool avxvnniint8
 Read or update the avxvnniint8 feature bit through flags.
bool avxvnniint16
 Read or update the avxvnniint16 feature bit through flags.
bool avx512bitalg
 Read or update the avx512bitalg feature bit through flags.
bool avx512vbmi
 Read or update the avx512vbmi feature bit through flags.
bool avx512vbmi2
 Read or update the avx512vbmi2 feature bit through flags.
bool sha
 Read or update the sha feature bit through flags.
bool vaes
 Read or update the vaes feature bit through flags.
bool avxifma
 Read or update the avxifma feature bit through flags.
bool adx
 Read or update the adx feature bit through flags.
bool sha512
 Read or update the sha512 feature bit through flags.
bool sm3
 Read or update the sm3 feature bit through flags.
bool sm4
 Read or update the sm4 feature bit through flags.
bool avxneconvert
 Read or update the avxneconvert feature bit through flags.

Static Public Attributes

static constexpr architecture family =x86
 Architecture family, independent of the compiler target.
static constexpr auto feature_count =detail::feature_traits<x86>::count
 Number of registered features in this family.

Detailed Description

Exact X86 feature requirements; construction does not add prerequisites.

Definition at line 107 of file isa.h.

Member Function Documentation

◆ set()

void native::isa< x86 >::set ( feature_type f,
bool value )
inlineconstexprnoexcept

Set or clear one feature. Requiring an invalid enum records an invalid set. Clearing an invalid enum does nothing; neither case indexes outside storage.

Definition at line 127 of file isa.h.

Here is the caller graph for this function:

The documentation for this struct was generated from the following file: