clang 19.0.0git
Macros | Functions
pmmintrin.h File Reference
#include <emmintrin.h>

Go to the source code of this file.

Macros

#define __DEFAULT_FN_ATTRS
 
#define _mm_loaddup_pd(dp)   _mm_load1_pd(dp)
 Moves and duplicates one double-precision value to double-precision values stored in a 128-bit vector of [2 x double].
 

Functions

static __inline__ __m128i __DEFAULT_FN_ATTRS _mm_lddqu_si128 (__m128i_u const *__p)
 Loads data from an unaligned memory location to elements in a 128-bit vector.
 
static __inline__ __m128 __DEFAULT_FN_ATTRS _mm_addsub_ps (__m128 __a, __m128 __b)
 Adds the even-indexed values and subtracts the odd-indexed values of two 128-bit vectors of [4 x float].
 
static __inline__ __m128 __DEFAULT_FN_ATTRS _mm_hadd_ps (__m128 __a, __m128 __b)
 Horizontally adds the adjacent pairs of values contained in two 128-bit vectors of [4 x float].
 
static __inline__ __m128 __DEFAULT_FN_ATTRS _mm_hsub_ps (__m128 __a, __m128 __b)
 Horizontally subtracts the adjacent pairs of values contained in two 128-bit vectors of [4 x float].
 
static __inline__ __m128 __DEFAULT_FN_ATTRS _mm_movehdup_ps (__m128 __a)
 Moves and duplicates odd-indexed values from a 128-bit vector of [4 x float] to float values stored in a 128-bit vector of [4 x float].
 
static __inline__ __m128 __DEFAULT_FN_ATTRS _mm_moveldup_ps (__m128 __a)
 Duplicates even-indexed values from a 128-bit vector of [4 x float] to float values stored in a 128-bit vector of [4 x float].
 
static __inline__ __m128d __DEFAULT_FN_ATTRS _mm_addsub_pd (__m128d __a, __m128d __b)
 Adds the even-indexed values and subtracts the odd-indexed values of two 128-bit vectors of [2 x double].
 
static __inline__ __m128d __DEFAULT_FN_ATTRS _mm_hadd_pd (__m128d __a, __m128d __b)
 Horizontally adds the pairs of values contained in two 128-bit vectors of [2 x double].
 
static __inline__ __m128d __DEFAULT_FN_ATTRS _mm_hsub_pd (__m128d __a, __m128d __b)
 Horizontally subtracts the pairs of values contained in two 128-bit vectors of [2 x double].
 
static __inline__ __m128d __DEFAULT_FN_ATTRS _mm_movedup_pd (__m128d __a)
 Moves and duplicates the double-precision value in the lower bits of a 128-bit vector of [2 x double] to double-precision values stored in a 128-bit vector of [2 x double].
 
static __inline__ void __DEFAULT_FN_ATTRS _mm_monitor (void const *__p, unsigned __extensions, unsigned __hints)
 Establishes a linear address memory range to be monitored and puts the processor in the monitor event pending state.
 
static __inline__ void __DEFAULT_FN_ATTRS _mm_mwait (unsigned __extensions, unsigned __hints)
 Used with the MONITOR instruction to wait while the processor is in the monitor event pending state.
 

Macro Definition Documentation

◆ __DEFAULT_FN_ATTRS

#define __DEFAULT_FN_ATTRS
Value:
__attribute__((__always_inline__, __nodebug__, \
__target__("sse3,no-evex512"), __min_vector_width__(128)))
_Float16 __2f16 __attribute__((ext_vector_type(2)))
Zeroes the upper 128 bits (bits 255:128) of all YMM registers.

Definition at line 20 of file pmmintrin.h.

◆ _mm_loaddup_pd

#define _mm_loaddup_pd (   dp)    _mm_load1_pd(dp)

Moves and duplicates one double-precision value to double-precision values stored in a 128-bit vector of [2 x double].

__m128d _mm_loaddup_pd(double const *dp);
#define _mm_loaddup_pd(dp)
Moves and duplicates one double-precision value to double-precision values stored in a 128-bit vector...
Definition: pmmintrin.h:232

This intrinsic corresponds to the VMOVDDUP instruction.

Parameters
dpA pointer to a double-precision value to be moved and duplicated.
Returns
A 128-bit vector of [2 x double] containing the moved and duplicated values.

Definition at line 232 of file pmmintrin.h.

Function Documentation

◆ _mm_addsub_pd()

static __inline__ __m128d __DEFAULT_FN_ATTRS _mm_addsub_pd ( __m128d  __a,
__m128d  __b 
)
static

Adds the even-indexed values and subtracts the odd-indexed values of two 128-bit vectors of [2 x double].

This intrinsic corresponds to the VADDSUBPD instruction.

Parameters
__aA 128-bit vector of [2 x double] containing the left source operand.
__bA 128-bit vector of [2 x double] containing the right source operand.
Returns
A 128-bit vector of [2 x double] containing the alternating sums and differences of both operands.

Definition at line 166 of file pmmintrin.h.

References __a, and __b.

◆ _mm_addsub_ps()

static __inline__ __m128 __DEFAULT_FN_ATTRS _mm_addsub_ps ( __m128  __a,
__m128  __b 
)
static

Adds the even-indexed values and subtracts the odd-indexed values of two 128-bit vectors of [4 x float].

This intrinsic corresponds to the VADDSUBPS instruction.

Parameters
__aA 128-bit vector of [4 x float] containing the left source operand.
__bA 128-bit vector of [4 x float] containing the right source operand.
Returns
A 128-bit vector of [4 x float] containing the alternating sums and differences of both operands.

Definition at line 58 of file pmmintrin.h.

References __a, and __b.

◆ _mm_hadd_pd()

static __inline__ __m128d __DEFAULT_FN_ATTRS _mm_hadd_pd ( __m128d  __a,
__m128d  __b 
)
static

Horizontally adds the pairs of values contained in two 128-bit vectors of [2 x double].

This intrinsic corresponds to the VHADDPD instruction.

Parameters
__aA 128-bit vector of [2 x double] containing one of the source operands. The horizontal sum of the values is stored in the lower bits of the destination.
__bA 128-bit vector of [2 x double] containing one of the source operands. The horizontal sum of the values is stored in the upper bits of the destination.
Returns
A 128-bit vector of [2 x double] containing the horizontal sums of both operands.

Definition at line 189 of file pmmintrin.h.

References __a, and __b.

◆ _mm_hadd_ps()

static __inline__ __m128 __DEFAULT_FN_ATTRS _mm_hadd_ps ( __m128  __a,
__m128  __b 
)
static

Horizontally adds the adjacent pairs of values contained in two 128-bit vectors of [4 x float].

This intrinsic corresponds to the VHADDPS instruction.

Parameters
__aA 128-bit vector of [4 x float] containing one of the source operands. The horizontal sums of the values are stored in the lower bits of the destination.
__bA 128-bit vector of [4 x float] containing one of the source operands. The horizontal sums of the values are stored in the upper bits of the destination.
Returns
A 128-bit vector of [4 x float] containing the horizontal sums of both operands.

Definition at line 81 of file pmmintrin.h.

References __a, and __b.

◆ _mm_hsub_pd()

static __inline__ __m128d __DEFAULT_FN_ATTRS _mm_hsub_pd ( __m128d  __a,
__m128d  __b 
)
static

Horizontally subtracts the pairs of values contained in two 128-bit vectors of [2 x double].

This intrinsic corresponds to the VHSUBPD instruction.

Parameters
__aA 128-bit vector of [2 x double] containing one of the source operands. The horizontal difference of the values is stored in the lower bits of the destination.
__bA 128-bit vector of [2 x double] containing one of the source operands. The horizontal difference of the values is stored in the upper bits of the destination.
Returns
A 128-bit vector of [2 x double] containing the horizontal differences of both operands.

Definition at line 212 of file pmmintrin.h.

References __a, and __b.

◆ _mm_hsub_ps()

static __inline__ __m128 __DEFAULT_FN_ATTRS _mm_hsub_ps ( __m128  __a,
__m128  __b 
)
static

Horizontally subtracts the adjacent pairs of values contained in two 128-bit vectors of [4 x float].

This intrinsic corresponds to the VHSUBPS instruction.

Parameters
__aA 128-bit vector of [4 x float] containing one of the source operands. The horizontal differences between the values are stored in the lower bits of the destination.
__bA 128-bit vector of [4 x float] containing one of the source operands. The horizontal differences between the values are stored in the upper bits of the destination.
Returns
A 128-bit vector of [4 x float] containing the horizontal differences of both operands.

Definition at line 104 of file pmmintrin.h.

References __a, and __b.

◆ _mm_lddqu_si128()

static __inline__ __m128i __DEFAULT_FN_ATTRS _mm_lddqu_si128 ( __m128i_u const *  __p)
static

Loads data from an unaligned memory location to elements in a 128-bit vector.

If the address of the data is not 16-byte aligned, the instruction may read two adjacent aligned blocks of memory to retrieve the requested data.

This intrinsic corresponds to the VLDDQU instruction.

Parameters
__pA pointer to a 128-bit integer vector containing integer values.
Returns
A 128-bit vector containing the moved values.

Definition at line 39 of file pmmintrin.h.

References __p.

◆ _mm_monitor()

static __inline__ void __DEFAULT_FN_ATTRS _mm_monitor ( void const *  __p,
unsigned  __extensions,
unsigned  __hints 
)
static

Establishes a linear address memory range to be monitored and puts the processor in the monitor event pending state.

Data stored in the monitored address range causes the processor to exit the pending state.

The MONITOR instruction can be used in kernel mode, and in other modes if MSR C001_0015h[MonMwaitUserEn] is set.

This intrinsic corresponds to the MONITOR instruction.

Parameters
__pThe memory range to be monitored. The size of the range is determined by CPUID function 0000_0005h.
__extensionsOptional extensions for the monitoring state.
__hintsOptional hints for the monitoring state.

Definition at line 272 of file pmmintrin.h.

References __p.

◆ _mm_movedup_pd()

static __inline__ __m128d __DEFAULT_FN_ATTRS _mm_movedup_pd ( __m128d  __a)
static

Moves and duplicates the double-precision value in the lower bits of a 128-bit vector of [2 x double] to double-precision values stored in a 128-bit vector of [2 x double].

This intrinsic corresponds to the VMOVDDUP instruction.

Parameters
__aA 128-bit vector of [2 x double]. Bits [63:0] are written to bits [127:64] and [63:0] of the destination.
Returns
A 128-bit vector of [2 x double] containing the moved and duplicated values.

Definition at line 248 of file pmmintrin.h.

References __a.

Referenced by _mm_mask_movedup_pd(), and _mm_maskz_movedup_pd().

◆ _mm_movehdup_ps()

static __inline__ __m128 __DEFAULT_FN_ATTRS _mm_movehdup_ps ( __m128  __a)
static

Moves and duplicates odd-indexed values from a 128-bit vector of [4 x float] to float values stored in a 128-bit vector of [4 x float].

This intrinsic corresponds to the VMOVSHDUP instruction.

Parameters
__aA 128-bit vector of [4 x float].
Bits [127:96] of the source are written to bits [127:96] and [95:64] of the destination.
Bits [63:32] of the source are written to bits [63:32] and [31:0] of the destination.
Returns
A 128-bit vector of [4 x float] containing the moved and duplicated values.

Definition at line 126 of file pmmintrin.h.

References __a.

Referenced by _mm_mask_movehdup_ps(), and _mm_maskz_movehdup_ps().

◆ _mm_moveldup_ps()

static __inline__ __m128 __DEFAULT_FN_ATTRS _mm_moveldup_ps ( __m128  __a)
static

Duplicates even-indexed values from a 128-bit vector of [4 x float] to float values stored in a 128-bit vector of [4 x float].

This intrinsic corresponds to the VMOVSLDUP instruction.

Parameters
__aA 128-bit vector of [4 x float]
Bits [95:64] of the source are written to bits [127:96] and [95:64] of the destination.
Bits [31:0] of the source are written to bits [63:32] and [31:0] of the destination.
Returns
A 128-bit vector of [4 x float] containing the moved and duplicated values.

Definition at line 147 of file pmmintrin.h.

References __a.

Referenced by _mm_mask_moveldup_ps(), and _mm_maskz_moveldup_ps().

◆ _mm_mwait()

static __inline__ void __DEFAULT_FN_ATTRS _mm_mwait ( unsigned  __extensions,
unsigned  __hints 
)
static

Used with the MONITOR instruction to wait while the processor is in the monitor event pending state.

Data stored in the monitored address range, or an interrupt, causes the processor to exit the pending state.

The MWAIT instruction can be used in kernel mode, and in other modes if MSR C001_0015h[MonMwaitUserEn] is set.

This intrinsic corresponds to the MWAIT instruction.

Parameters
__extensionsOptional extensions for the monitoring state, which can vary by processor.
__hintsOptional hints for the monitoring state, which can vary by processor.

Definition at line 294 of file pmmintrin.h.