30#ifndef SIMD_VEC_MASK_IMPL_INTEL_32_H_
31#define SIMD_VEC_MASK_IMPL_INTEL_32_H_
35#include "../mask_impl_emu.H"
38#include "intrins_intel.H"
40#if defined(SIMDVEC_INTEL_ENABLE) && defined(_SIMD_VEC_32_AVAIL_) && \
41 !defined(SIMDVEC_SANDBOX)
45template <
typename T, SIMD_ENABLE_IF(sizeof(T) == 4)>
46static SIMD_INLINE Vec<T, 32> maskz_loadu(
const Mask<T, 32> &k,
53template <
typename T, SIMD_ENABLE_IF(sizeof(T) == 8),
typename =
void>
54static SIMD_INLINE Vec<T, 32> maskz_loadu(
const Mask<T, 32> &k,
61template <
typename T, SIMD_ENABLE_IF(sizeof(T) == 4 || sizeof(T) == 8)>
62static SIMD_INLINE Vec<T, 32> mask_loadu(
const Vec<T, 32> &src,
63 const Mask<T, 32> &k,
const T *
const p)
65 return mask::mask_ifelse(k, mask::maskz_loadu(k, p), src);
68template <
typename T, SIMD_ENABLE_IF(sizeof(T) == 4 || sizeof(T) == 8)>
69static SIMD_INLINE Vec<T, 32> maskz_load(
const Mask<T, 32> &k,
const T *
const p)
71 return mask::maskz_loadu(k, p);
74template <
typename T, SIMD_ENABLE_IF(sizeof(T) == 4 || sizeof(T) == 8)>
75static SIMD_INLINE Vec<T, 32> mask_load(
const Vec<T, 32> &src,
76 const Mask<T, 32> &k,
const T *
const p)
78 return mask::mask_loadu(src, k, p);
81template <
typename T, SIMD_ENABLE_IF(sizeof(T) == 4)>
82static SIMD_INLINE
void mask_storeu(T *
const p,
const Mask<T, 32> &k,
85 _mm256_maskstore_ps(
reinterpret_cast<Float *
>(p),
89template <
typename T, SIMD_ENABLE_IF(sizeof(T) == 8),
typename =
void>
90static SIMD_INLINE
void mask_storeu(T *
const p,
const Mask<T, 32> &k,
93 _mm256_maskstore_pd(
reinterpret_cast<Double *
>(p),
98template <
typename T, SIMD_ENABLE_IF(sizeof(T) == 4 || sizeof(T) == 8)>
99static SIMD_INLINE
void mask_store(T *
const p,
const Mask<T, 32> &k,
102 mask::mask_storeu(p, k, a);
float Float
Single-precision floating point number (32-bit)
Definition types.H:56
double Double
Double-precision floating point number (64-bit)
Definition types.H:57
static Vec< Tout, SIMD_WIDTH > reinterpret(const Vec< Tin, SIMD_WIDTH > &a)
Reinterprets a given Vec as a Vec with a different element type.
Definition base.H:58
Namespace for T-SIMD.
Definition time_measurement.H:161