[RISCV] Add Qualcomm uC Xqcics(Conditional Select) extension (#119504)
[llvm-project.git] / clang / lib / Headers / avx512ifmaintrin.h
blob9468d17556e7214171c90d066234d03a9b80e5af
1 /*===------------- avx512ifmaintrin.h - IFMA intrinsics ------------------===
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
8 *===-----------------------------------------------------------------------===
9 */
10 #ifndef __IMMINTRIN_H
11 #error "Never use <avx512ifmaintrin.h> directly; include <immintrin.h> instead."
12 #endif
14 #ifndef __IFMAINTRIN_H
15 #define __IFMAINTRIN_H
17 /* Define the default attributes for the functions in this file. */
18 #define __DEFAULT_FN_ATTRS \
19 __attribute__((__always_inline__, __nodebug__, \
20 __target__("avx512ifma,evex512"), __min_vector_width__(512)))
22 static __inline__ __m512i __DEFAULT_FN_ATTRS
23 _mm512_madd52hi_epu64 (__m512i __X, __m512i __Y, __m512i __Z)
25 return (__m512i)__builtin_ia32_vpmadd52huq512((__v8di) __X, (__v8di) __Y,
26 (__v8di) __Z);
29 static __inline__ __m512i __DEFAULT_FN_ATTRS
30 _mm512_mask_madd52hi_epu64 (__m512i __W, __mmask8 __M, __m512i __X, __m512i __Y)
32 return (__m512i)__builtin_ia32_selectq_512(__M,
33 (__v8di)_mm512_madd52hi_epu64(__W, __X, __Y),
34 (__v8di)__W);
37 static __inline__ __m512i __DEFAULT_FN_ATTRS
38 _mm512_maskz_madd52hi_epu64 (__mmask8 __M, __m512i __X, __m512i __Y, __m512i __Z)
40 return (__m512i)__builtin_ia32_selectq_512(__M,
41 (__v8di)_mm512_madd52hi_epu64(__X, __Y, __Z),
42 (__v8di)_mm512_setzero_si512());
45 static __inline__ __m512i __DEFAULT_FN_ATTRS
46 _mm512_madd52lo_epu64 (__m512i __X, __m512i __Y, __m512i __Z)
48 return (__m512i)__builtin_ia32_vpmadd52luq512((__v8di) __X, (__v8di) __Y,
49 (__v8di) __Z);
52 static __inline__ __m512i __DEFAULT_FN_ATTRS
53 _mm512_mask_madd52lo_epu64 (__m512i __W, __mmask8 __M, __m512i __X, __m512i __Y)
55 return (__m512i)__builtin_ia32_selectq_512(__M,
56 (__v8di)_mm512_madd52lo_epu64(__W, __X, __Y),
57 (__v8di)__W);
60 static __inline__ __m512i __DEFAULT_FN_ATTRS
61 _mm512_maskz_madd52lo_epu64 (__mmask8 __M, __m512i __X, __m512i __Y, __m512i __Z)
63 return (__m512i)__builtin_ia32_selectq_512(__M,
64 (__v8di)_mm512_madd52lo_epu64(__X, __Y, __Z),
65 (__v8di)_mm512_setzero_si512());
68 #undef __DEFAULT_FN_ATTRS
70 #endif