Developer Guide and Reference

Contents

Intrinsics for Logical Operations

The prototypes for Intel® Advanced Vector Extensions 512 (Intel® AVX-512) intrinsics are located in the
zmmintrin.h
header file.
To use these intrinsics, include the
immintrin.h
file as follows:
#include <immintrin.h>
variable
definition
src
source element to use based on writemask result
k
writemask used as a selector
a
first source vector element
b
second source vector element
c
third source vector element
imm
comparison predicate, which can be any of the following values:
  • _MM_CMPINT_EQ
    - Equal
  • _MM_CMPINT_LT
    - Less than
  • _MM_CMPINT_LE
    - Less than or Equal
  • _MM_CMPINT_NE
    - Not Equal
  • _MM_CMPINT_NLT
    - Not Less than
  • _MM_CMPINT_GE
    - Greater than or Equal
  • _MM_CMPINT_NLE
    - Not Less than or Equal
  • _MM_CMPINT_GT
    - Greater than
_mm_mask_andnot_pd
__m128d _mm_mask_andnot_pd(__m128d src, __mmask8 k, __m128d a, __m128d b)
CPUID Flags: AVX512DQ, AVX512VL
Instruction(s): vandnpd
Compute the bitwise AND NOT of packed double-precision (64-bit) floating-point elements in
a
and
b
, and return the results using writemask
k
(elements are copied from
src
when the corresponding mask bit is not set).
_mm_maskz_andnot_pd
__m128d _mm_maskz_andnot_pd(__mmask8 k, __m128d a, __m128d b)
CPUID Flags: AVX512DQ, AVX512VL
Instruction(s): vandnpd
Compute the bitwise AND NOT of packed double-precision (64-bit) floating-point elements in
a
and
b
, and return the results using zeromask
k
(elements are zeroed out when the corresponding mask bit is not set).
_mm256_mask_andnot_pd
__m256d _mm256_mask_andnot_pd(__m256d src, __mmask8 k, __m256d a, __m256d b)
CPUID Flags: AVX512DQ, AVX512VL
Instruction(s): vandnpd
Compute the bitwise AND NOT of packed double-precision (64-bit) floating-point elements in
a
and
b
, and return the results using writemask
k
(elements are copied from
src
when the corresponding mask bit is not set).
_mm256_maskz_andnot_pd
__m256d _mm256_maskz_andnot_pd(__mmask8 k, __m256d a, __m256d b)
CPUID Flags: AVX512DQ, AVX512VL
Instruction(s): vandnpd
Compute the bitwise AND NOT of packed double-precision (64-bit) floating-point elements in
a
and
b
, and return the results using zeromask
k
(elements are zeroed out when the corresponding mask bit is not set).
_mm512_andnot_pd
__m512d _mm512_andnot_pd(__m512d a, __m512d b)
CPUID Flags: AVX512DQ
Instruction(s): vandnpd
Compute the bitwise AND NOT of packed double-precision (64-bit) floating-point elements in
a
and
b
, and return the results.
_mm512_mask_andnot_pd
__m512d _mm512_mask_andnot_pd(__m512d src, __mmask8 k, __m512d a, __m512d b)
CPUID Flags: AVX512DQ
Instruction(s): vandnpd
Compute the bitwise AND NOT of packed double-precision (64-bit) floating-point elements in
a
and
b
, and return the results using writemask
k
(elements are copied from
src
when the corresponding mask bit is not set).
_mm512_maskz_andnot_pd
__m512d _mm512_maskz_andnot_pd(__mmask8 k, __m512d a, __m512d b)
CPUID Flags: AVX512DQ
Instruction(s): vandnpd
Compute the bitwise AND NOT of packed double-precision (64-bit) floating-point elements in
a
and
b
, and return the results using zeromask
k
(elements are zeroed out when the corresponding mask bit is not set).
_mm_mask_andnot_ps
__m128 _mm_mask_andnot_ps(__m128 src, __mmask8 k, __m128 a, __m128 b)
CPUID Flags: AVX512DQ, AVX512VL
Instruction(s): vandnps
Compute the bitwise AND NOT of packed single-precision (32-bit) floating-point elements in
a
and
b
, and return the results using writemask
k
(elements are copied from
src
when the corresponding mask bit is not set).
_mm_maskz_andnot_ps
__m128 _mm_maskz_andnot_ps(__mmask8 k, __m128 a, __m128 b)
CPUID Flags: AVX512DQ, AVX512VL
Instruction(s): vandnps
Compute the bitwise AND NOT of packed single-precision (32-bit) floating-point elements in
a
and
b
, and return the results using zeromask
k
(elements are zeroed out when the corresponding mask bit is not set).
_mm256_mask_andnot_ps
__m256 _mm256_mask_andnot_ps(__m256 src, __mmask8 k, __m256 a, __m256 b)
CPUID Flags: AVX512DQ, AVX512VL
Instruction(s): vandnps
Compute the bitwise AND NOT of packed single-precision (32-bit) floating-point elements in
a
and
b
, and return the results using writemask
k
(elements are copied from
src
when the corresponding mask bit is not set).
_mm256_maskz_andnot_ps
__m256 _mm256_maskz_andnot_ps(__mmask8 k, __m256 a, __m256 b)
CPUID Flags: AVX512DQ, AVX512VL
Instruction(s): vandnps
Compute the bitwise AND NOT of packed single-precision (32-bit) floating-point elements in
a
and
b
, and return the results using zeroma