clang 22.0.0git
avx512ifmaintrin.h
Go to the documentation of this file.
1/*===------------- avx512ifmaintrin.h - IFMA intrinsics ------------------===
2 *
3 *
4 * Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
5 * See https://llvm.org/LICENSE.txt for license information.
6 * SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
7 *
8 *===-----------------------------------------------------------------------===
9 */
10#ifndef __IMMINTRIN_H
11#error "Never use <avx512ifmaintrin.h> directly; include <immintrin.h> instead."
12#endif
13
14#ifndef __IFMAINTRIN_H
15#define __IFMAINTRIN_H
16
17/* Define the default attributes for the functions in this file. */
18#if defined(__cplusplus) && (__cplusplus >= 201103L)
19#define __DEFAULT_FN_ATTRS \
20 constexpr \
21 __attribute__((__always_inline__, __nodebug__, __target__("avx512ifma"), \
22 __min_vector_width__(512)))
23#else
24#define __DEFAULT_FN_ATTRS \
25 __attribute__((__always_inline__, __nodebug__, __target__("avx512ifma"), \
26 __min_vector_width__(512)))
27#endif
28
29static __inline__ __m512i __DEFAULT_FN_ATTRS
30_mm512_madd52hi_epu64(__m512i __X, __m512i __Y, __m512i __Z) {
31 return (__m512i)__builtin_ia32_vpmadd52huq512((__v8di)__X, (__v8di)__Y,
32 (__v8di)__Z);
33}
34
36 __m512i __W, __mmask8 __M, __m512i __X, __m512i __Y) {
37 return (__m512i)__builtin_ia32_selectq_512(
38 __M, (__v8di)_mm512_madd52hi_epu64(__W, __X, __Y), (__v8di)__W);
39}
40
42 __mmask8 __M, __m512i __X, __m512i __Y, __m512i __Z) {
43 return (__m512i)__builtin_ia32_selectq_512(
44 __M, (__v8di)_mm512_madd52hi_epu64(__X, __Y, __Z),
45 (__v8di)_mm512_setzero_si512());
46}
47
48static __inline__ __m512i __DEFAULT_FN_ATTRS
49_mm512_madd52lo_epu64(__m512i __X, __m512i __Y, __m512i __Z) {
50 return (__m512i)__builtin_ia32_vpmadd52luq512((__v8di)__X, (__v8di)__Y,
51 (__v8di)__Z);
52}
53
55 __m512i __W, __mmask8 __M, __m512i __X, __m512i __Y) {
56 return (__m512i)__builtin_ia32_selectq_512(
57 __M, (__v8di)_mm512_madd52lo_epu64(__W, __X, __Y), (__v8di)__W);
58}
59
61 __mmask8 __M, __m512i __X, __m512i __Y, __m512i __Z) {
62 return (__m512i)__builtin_ia32_selectq_512(
63 __M, (__v8di)_mm512_madd52lo_epu64(__X, __Y, __Z),
64 (__v8di)_mm512_setzero_si512());
65}
66
67#undef __DEFAULT_FN_ATTRS
68
69#endif
#define __DEFAULT_FN_ATTRS
unsigned char __mmask8
static __inline __m512i __DEFAULT_FN_ATTRS512_CONSTEXPR _mm512_setzero_si512(void)
static __inline__ __m512i __DEFAULT_FN_ATTRS _mm512_maskz_madd52lo_epu64(__mmask8 __M, __m512i __X, __m512i __Y, __m512i __Z)
static __inline__ __m512i __DEFAULT_FN_ATTRS _mm512_madd52hi_epu64(__m512i __X, __m512i __Y, __m512i __Z)
static __inline__ __m512i __DEFAULT_FN_ATTRS _mm512_mask_madd52hi_epu64(__m512i __W, __mmask8 __M, __m512i __X, __m512i __Y)
static __inline__ __m512i __DEFAULT_FN_ATTRS _mm512_mask_madd52lo_epu64(__m512i __W, __mmask8 __M, __m512i __X, __m512i __Y)
static __inline__ __m512i __DEFAULT_FN_ATTRS _mm512_madd52lo_epu64(__m512i __X, __m512i __Y, __m512i __Z)
static __inline__ __m512i __DEFAULT_FN_ATTRS _mm512_maskz_madd52hi_epu64(__mmask8 __M, __m512i __X, __m512i __Y, __m512i __Z)
__inline unsigned int unsigned int __Y
Definition bmi2intrin.h:19