35#ifndef _BLAZE_MATH_SIMD_SETALL_H_
36#define _BLAZE_MATH_SIMD_SETALL_H_
69 setall_epi8( T v0 = 0, T v1 = 0, T v2 = 0, T v3 = 0
70 , T v4 = 0, T v5 = 0, T v6 = 0, T v7 = 0
71 , T v8 = 0, T v9 = 0, T v10 = 0, T v11 = 0
72 , T v12 = 0, T v13 = 0, T v14 = 0, T v15 = 0
73 , T v16 = 0, T v17 = 0, T v18 = 0, T v19 = 0
74 , T v20 = 0, T v21 = 0, T v22 = 0, T v23 = 0
75 , T v24 = 0, T v25 = 0, T v26 = 0, T v27 = 0
76 , T v28 = 0, T v29 = 0, T v30 = 0, T v31 = 0
77 , T v32 = 0, T v33 = 0, T v34 = 0, T v35 = 0
78 , T v36 = 0, T v37 = 0, T v38 = 0, T v39 = 0
79 , T v40 = 0, T v41 = 0, T v42 = 0, T v43 = 0
80 , T v44 = 0, T v45 = 0, T v46 = 0, T v47 = 0
81 , T v48 = 0, T v49 = 0, T v50 = 0, T v51 = 0
82 , T v52 = 0, T v53 = 0, T v54 = 0, T v55 = 0
83 , T v56 = 0, T v57 = 0, T v58 = 0, T v59 = 0
84 , T v60 = 0, T v61 = 0, T v62 = 0, T v63 = 0 ) noexcept
86 return _mm512_set_epi8( v63, v62, v61, v60, v59, v58, v57, v56, v55, v54, v53, v52, v51, v50, v49, v48
87 , v47, v46, v45, v44, v43, v42, v41, v40, v39, v38, v37, v36, v35, v34, v33, v32
88 , v31, v30, v29, v28, v27, v26, v25, v24, v23, v22, v21, v20, v19, v18, v17, v16
89 , v15, v14, v13, v12, v11, v10, v9, v8, v7, v6, v5, v4, v3, v2, v1, v0 );
94 setall_epi8( T v0 = 0, T v1 = 0, T v2 = 0, T v3 = 0
95 , T v4 = 0, T v5 = 0, T v6 = 0, T v7 = 0
96 , T v8 = 0, T v9 = 0, T v10 = 0, T v11 = 0
97 , T v12 = 0, T v13 = 0, T v14 = 0, T v15 = 0
98 , T v16 = 0, T v17 = 0, T v18 = 0, T v19 = 0
99 , T v20 = 0, T v21 = 0, T v22 = 0, T v23 = 0
100 , T v24 = 0, T v25 = 0, T v26 = 0, T v27 = 0
101 , T v28 = 0, T v29 = 0, T v30 = 0, T v31 = 0 ) noexcept
103 return _mm256_set_epi8( v31, v30, v29, v28, v27, v26, v25, v24, v23, v22, v21, v20, v19, v18, v17, v16
104 , v15, v14, v13, v12, v11, v10, v9, v8, v7, v6, v5, v4, v3, v2, v1, v0 );
107template<
typename T >
109 setall_epi8( T v0 = 0, T v1 = 0, T v2 = 0, T v3 = 0
110 , T v4 = 0, T v5 = 0, T v6 = 0, T v7 = 0
111 , T v8 = 0, T v9 = 0, T v10 = 0, T v11 = 0
112 , T v12 = 0, T v13 = 0, T v14 = 0, T v15 = 0 ) noexcept
114 return _mm_set_epi8( v15, v14, v13, v12, v11, v10, v9, v8, v7, v6, v5, v4, v3, v2, v1, v0 );
117template<
typename T >
119 setall_epi8( T v0 = 0 ) noexcept
155 return setall_epi8( v0, vs... );
162#if BLAZE_AVX512F_MODE
163template<
typename T >
182 return _mm512_set_epi8( v31.imag(), v31.real(), v30.imag(), v30.real()
183 , v29.imag(), v29.real(), v28.imag(), v28.real()
184 , v27.imag(), v27.real(), v26.imag(), v26.real()
185 , v25.imag(), v25.real(), v24.imag(), v24.real()
186 , v23.imag(), v23.real(), v22.imag(), v22.real()
187 , v21.imag(), v21.real(), v20.imag(), v20.real()
188 , v19.imag(), v19.real(), v18.imag(), v18.real()
189 , v17.imag(), v17.real(), v16.imag(), v16.real()
190 , v15.imag(), v15.real(), v14.imag(), v14.real()
191 , v13.imag(), v13.real(), v12.imag(), v12.real()
192 , v11.imag(), v11.real(), v10.imag(), v10.real()
193 , v9.imag(), v9.real(), v8.imag(), v8.real()
194 , v7.imag(), v7.real(), v6.imag(), v6.real()
195 , v5.imag(), v5.real(), v4.imag(), v4.real()
196 , v3.imag(), v3.real(), v2.imag(), v2.real()
197 , v1.imag(), v1.real(), v0.imag(), v0.real() );
200template<
typename T >
202 setall_epi8(
const complex<T>& v0 = 0,
const complex<T>& v1 = 0
203 ,
const complex<T>& v2 = 0,
const complex<T>& v3 = 0
204 ,
const complex<T>& v4 = 0,
const complex<T>& v5 = 0
205 ,
const complex<T>& v6 = 0,
const complex<T>& v7 = 0
206 ,
const complex<T>& v8 = 0,
const complex<T>& v9 = 0
207 ,
const complex<T>& v10 = 0,
const complex<T>& v11 = 0
208 ,
const complex<T>& v12 = 0,
const complex<T>& v13 = 0
209 ,
const complex<T>& v14 = 0,
const complex<T>& v15 = 0 ) noexcept
211 return _mm256_set_epi8( v15.imag(), v15.real(), v14.imag(), v14.real()
212 , v13.imag(), v13.real(), v12.imag(), v12.real()
213 , v11.imag(), v11.real(), v10.imag(), v10.real()
214 , v9.imag(), v9.real(), v8.imag(), v8.real()
215 , v7.imag(), v7.real(), v6.imag(), v6.real()
216 , v5.imag(), v5.real(), v4.imag(), v4.real()
217 , v3.imag(), v3.real(), v2.imag(), v2.real()
218 , v1.imag(), v1.real(), v0.imag(), v0.real() );
221template<
typename T >
223 setall_epi8(
const complex<T>& v0 = 0,
const complex<T>& v1 = 0
224 ,
const complex<T>& v2 = 0,
const complex<T>& v3 = 0
225 ,
const complex<T>& v4 = 0,
const complex<T>& v5 = 0
226 ,
const complex<T>& v6 = 0,
const complex<T>& v7 = 0 ) noexcept
228 return _mm_set_epi8( v7.imag(), v7.real(), v6.imag(), v6.real()
229 , v5.imag(), v5.real(), v4.imag(), v4.real()
230 , v3.imag(), v3.real(), v2.imag(), v2.real()
231 , v1.imag(), v1.real(), v0.imag(), v0.real() );
234template<
typename T >
236 setall_epi8(
const complex<T>& v0 = 0 ) noexcept
270 setall(
const complex<T>& v0,
const complex<Ts>&... vs )
noexcept
272 return setall_epi8( v0, vs... );
289#if BLAZE_AVX512F_MODE
290template<
typename T >
292 setall_epi16( T v0 = 0, T v1 = 0, T v2 = 0, T v3 = 0
293 , T v4 = 0, T v5 = 0, T v6 = 0, T v7 = 0
294 , T v8 = 0, T v9 = 0, T v10 = 0, T v11 = 0
295 , T v12 = 0, T v13 = 0, T v14 = 0, T v15 = 0
296 , T v16 = 0, T v17 = 0, T v18 = 0, T v19 = 0
297 , T v20 = 0, T v21 = 0, T v22 = 0, T v23 = 0
298 , T v24 = 0, T v25 = 0, T v26 = 0, T v27 = 0
299 , T v28 = 0, T v29 = 0, T v30 = 0, T v31 = 0 ) noexcept
301 return _mm512_set_epi16( v31, v30, v29, v28, v27, v26, v25, v24, v23, v22, v21, v20, v19, v18, v17, v16
302 , v15, v14, v13, v12, v11, v10, v9, v8, v7, v6, v5, v4, v3, v2, v1, v0 );
305template<
typename T >
307 setall_epi16( T v0 = 0, T v1 = 0, T v2 = 0, T v3 = 0
308 , T v4 = 0, T v5 = 0, T v6 = 0, T v7 = 0
309 , T v8 = 0, T v9 = 0, T v10 = 0, T v11 = 0
310 , T v12 = 0, T v13 = 0, T v14 = 0, T v15 = 0 ) noexcept
312 return _mm256_set_epi16( v15, v14, v13, v12, v11, v10, v9, v8, v7, v6, v5, v4, v3, v2, v1, v0 );
315template<
typename T >
317 setall_epi16( T v0 = 0, T v1 = 0, T v2 = 0, T v3 = 0
318 , T v4 = 0, T v5 = 0, T v6 = 0, T v7 = 0 ) noexcept
320 return _mm_set_epi16( v7, v6, v5, v4, v3, v2, v1, v0 );
323template<
typename T >
325 setall_epi16( T v0 = 0 ) noexcept
361 return setall_epi16( v0, vs... );
368#if BLAZE_AVX512F_MODE
369template<
typename T >
380 return _mm512_set_epi16( v15.imag(), v15.real(), v14.imag(), v14.real()
381 , v13.imag(), v13.real(), v12.imag(), v12.real()
382 , v11.imag(), v11.real(), v10.imag(), v10.real()
383 , v9.imag(), v9.real(), v8.imag(), v8.real()
384 , v7.imag(), v7.real(), v6.imag(), v6.real()
385 , v5.imag(), v5.real(), v4.imag(), v4.real()
386 , v3.imag(), v3.real(), v2.imag(), v2.real()
387 , v1.imag(), v1.real(), v0.imag(), v0.real() );
390template<
typename T >
392 setall_epi16(
const complex<T>& v0 = 0,
const complex<T>& v1 = 0
393 ,
const complex<T>& v2 = 0,
const complex<T>& v3 = 0
394 ,
const complex<T>& v4 = 0,
const complex<T>& v5 = 0
395 ,
const complex<T>& v6 = 0,
const complex<T>& v7 = 0 ) noexcept
397 return _mm256_set_epi16( v7.imag(), v7.real(), v6.imag(), v6.real()
398 , v5.imag(), v5.real(), v4.imag(), v4.real()
399 , v3.imag(), v3.real(), v2.imag(), v2.real()
400 , v1.imag(), v1.real(), v0.imag(), v0.real() );
403template<
typename T >
405 setall_epi16(
const complex<T>& v0 = 0,
const complex<T>& v1 = 0
406 ,
const complex<T>& v2 = 0,
const complex<T>& v3 = 0 ) noexcept
408 return _mm_set_epi16( v3.imag(), v3.real(), v2.imag(), v2.real()
409 , v1.imag(), v1.real(), v0.imag(), v0.real() );
412template<
typename T >
414 setall_epi16(
const complex<T>& v0 = 0 ) noexcept
448 setall(
const complex<T>& v0,
const complex<Ts>&... vs )
noexcept
450 return setall_epi16( v0, vs... );
467#if BLAZE_AVX512F_MODE
468template<
typename T >
470 setall_epi32( T v0 = 0, T v1 = 0, T v2 = 0, T v3 = 0
471 , T v4 = 0, T v5 = 0, T v6 = 0, T v7 = 0
472 , T v8 = 0, T v9 = 0, T v10 = 0, T v11 = 0
473 , T v12 = 0, T v13 = 0, T v14 = 0, T v15 = 0 ) noexcept
475 return _mm512_set_epi32( v15, v14, v13, v12, v11, v10, v9, v8, v7, v6, v5, v4, v3, v2, v1, v0 );
478template<
typename T >
480 setall_epi32( T v0 = 0, T v1 = 0, T v2 = 0, T v3 = 0
481 , T v4 = 0, T v5 = 0, T v6 = 0, T v7 = 0 ) noexcept
483 return _mm256_set_epi32( v7, v6, v5, v4, v3, v2, v1, v0 );
486template<
typename T >
488 setall_epi32( T v0 = 0, T v1 = 0, T v2 = 0, T v3 = 0 ) noexcept
490 return _mm_set_epi32( v3, v2, v1, v0 );
493template<
typename T >
495 setall_epi32( T v0 = 0 ) noexcept
531 return setall_epi32( v0, vs... );
538#if BLAZE_AVX512F_MODE
539template<
typename T >
546 return _mm512_set_epi32( v7.imag(), v7.real(), v6.imag(), v6.real()
547 , v5.imag(), v5.real(), v4.imag(), v4.real()
548 , v3.imag(), v3.real(), v2.imag(), v2.real()
549 , v1.imag(), v1.real(), v0.imag(), v0.real() );
552template<
typename T >
554 setall_epi32(
const complex<T>& v0 = 0,
const complex<T>& v1 = 0
555 ,
const complex<T>& v2 = 0,
const complex<T>& v3 = 0 ) noexcept
557 return _mm256_set_epi32( v3.imag(), v3.real(), v2.imag(), v2.real()
558 , v1.imag(), v1.real(), v0.imag(), v0.real() );
561template<
typename T >
563 setall_epi32(
const complex<T>& v0 = 0,
const complex<T>& v1 = 0 ) noexcept
565 return _mm_set_epi32( v1.imag(), v1.real(), v0.imag(), v0.real() );
568template<
typename T >
570 setall_epi32(
const complex<T>& v0 = 0 ) noexcept
604 setall(
const complex<T>& v0,
const complex<Ts>&... vs )
noexcept
606 return setall_epi32( v0, vs... );
623#if BLAZE_AVX512F_MODE
624template<
typename T >
626 setall_epi64( T v0 = 0, T v1 = 0, T v2 = 0, T v3 = 0
627 , T v4 = 0, T v5 = 0, T v6 = 0, T v7 = 0 ) noexcept
629 return _mm512_set_epi64( v7, v6, v5, v4, v3, v2, v1, v0 );
632template<
typename T >
634 setall_epi64( T v0 = 0, T v1 = 0, T v2 = 0, T v3 = 0 ) noexcept
636 return _mm256_set_epi64x( v3, v2, v1, v0 );
639template<
typename T >
641 setall_epi64( T v0 = 0, T v1 = 0 ) noexcept
643 return _mm_set_epi64x( v1, v0 );
646template<
typename T >
648 setall_epi64( T v0 = 0 ) noexcept
684 return setall_epi64( v0, vs... );
691#if BLAZE_AVX512F_MODE
692template<
typename T >
697 return _mm512_set_epi64( v3.imag(), v3.real(), v2.imag(), v2.real()
698 , v1.imag(), v1.real(), v0.imag(), v0.real() );
701template<
typename T >
703 setall_epi64(
const complex<T>& v0 = 0,
const complex<T>& v1 = 0 ) noexcept
705 return _mm256_set_epi64x( v1.imag(), v1.real(), v0.imag(), v0.real() );
708template<
typename T >
710 setall_epi64(
const complex<T>& v0 = 0 ) noexcept
712 return _mm_set_epi64x( v0.imag(), v0.real() );
715template<
typename T >
717 setall_epi64(
const complex<T>& v0 = 0 ) noexcept
751 setall(
const complex<T>& v0,
const complex<Ts>&... vs )
noexcept
753 return setall_epi64( v0, vs... );
770#if BLAZE_AVX512F_MODE
772 setall_ps(
float v0 = 0.0F,
float v1 = 0.0F,
float v2 = 0.0F,
float v3 = 0.0F
773 ,
float v4 = 0.0F,
float v5 = 0.0F,
float v6 = 0.0F,
float v7 = 0.0F
774 ,
float v8 = 0.0F,
float v9 = 0.0F,
float v10 = 0.0F,
float v11 = 0.0F
775 ,
float v12 = 0.0F,
float v13 = 0.0F,
float v14 = 0.0F,
float v15 = 0.0F ) noexcept
777 return _mm512_set_ps( v15, v14, v13, v12, v11, v10, v9, v8, v7, v6, v5, v4, v3, v2, v1, v0 );
781 setall_ps(
float v0 = 0.0F,
float v1 = 0.0F,
float v2 = 0.0F,
float v3 = 0.0F
782 ,
float v4 = 0.0F,
float v5 = 0.0F,
float v6 = 0.0F,
float v7 = 0.0F ) noexcept
784 return _mm256_set_ps( v7, v6, v5, v4, v3, v2, v1, v0 );
788 setall_ps(
float v0 = 0.0F,
float v1 = 0.0F,
float v2 = 0.0F,
float v3 = 0.0F ) noexcept
790 return _mm_set_ps( v3, v2, v1, v0 );
794 setall_ps(
float v1 = 0.0F,
float v0 = 0.0F ) noexcept
824template<
typename... Ts >
827 return setall_ps( v0, vs... );
834#if BLAZE_AVX512F_MODE
841 return _mm512_set_ps( v7.imag(), v7.real(), v6.imag(), v6.real()
842 , v5.imag(), v5.real(), v4.imag(), v4.real()
843 , v3.imag(), v3.real(), v2.imag(), v2.real()
844 , v1.imag(), v1.real(), v0.imag(), v0.real() );
848 setall_ps(
const complex<float>& v0 = 0.0F,
const complex<float>& v1 = 0.0F
849 ,
const complex<float>& v2 = 0.0F,
const complex<float>& v3 = 0.0F ) noexcept
851 return _mm256_set_ps( v3.imag(), v3.real(), v2.imag(), v2.real()
852 , v1.imag(), v1.real(), v0.imag(), v0.real() );
856 setall_ps(
const complex<float>& v0 = 0.0F,
const complex<float>& v1 = 0.0F ) noexcept
858 return _mm_set_ps( v1.imag(), v1.real(), v0.imag(), v0.real() );
862 setall_ps(
const complex<float>& v0 = 0.0F ) noexcept
892template<
typename... Ts >
895 return setall_ps( v0, vs... );
912#if BLAZE_AVX512F_MODE
914 setall_pd(
double v0 = 0.0,
double v1 = 0.0,
double v2 = 0.0,
double v3 = 0.0
915 ,
double v4 = 0.0,
double v5 = 0.0,
double v6 = 0.0,
double v7 = 0.0 ) noexcept
917 return _mm512_set_pd( v7, v6, v5, v4, v3, v2, v1, v0 );
921 setall_pd(
double v0 = 0.0,
double v1 = 0.0,
double v2 = 0.0,
double v3 = 0.0 ) noexcept
923 return _mm256_set_pd( v3, v2, v1, v0 );
927 setall_pd(
double v0 = 0.0,
double v1 = 0.0 ) noexcept
929 return _mm_set_pd( v1, v0 );
933 setall_pd(
double v0 = 0.0 ) noexcept
963template<
typename... Ts >
966 return setall_pd( v0, vs... );
973#if BLAZE_AVX512F_MODE
978 return _mm512_set_pd( v3.imag(), v3.real(), v2.imag(), v2.real()
979 , v1.imag(), v1.real(), v0.imag(), v0.real() );
983 setall_pd(
const complex<double>& v0 = 0.0,
const complex<double>& v1 = 0.0 ) noexcept
985 return _mm256_set_pd( v1.imag(), v1.real(), v0.imag(), v0.real() );
989 setall_pd(
const complex<double>& v0 = 0.0 ) noexcept
991 return _mm_set_pd( v0.imag(), v0.real() );
995 setall_pd(
const complex<double>& v0 = 0.0 ) noexcept
1025template<
typename... Ts >
1028 return setall_pd( v0, vs... );
Header file for the basic SIMD types.
Header file for the EnableIf class template.
Header file for the HasSize type trait.
Header file for the If class template.
Constraint on the data type.
Header file for the IsIntegral type trait.
Header file for the IsSigned type trait.
SIMD type for 64-bit double precision complex values.
SIMD type for 32-bit single precision complex values.
SIMD type for 16-bit signed integral complex values.
SIMD type for 32-bit signed integral complex values.
SIMD type for 64-bit signed integral complex values.
SIMD type for 8-bit signed integral complex values.
SIMD type for 16-bit unsigned integral complex values.
SIMD type for 32-bit unsigned integral complex values.
SIMD type for 64-bit unsigned integral complex values.
SIMD type for 8-bit unsigned integral complex values.
SIMD type for 64-bit double precision floating point data values.
SIMD type for 32-bit single precision floating point data values.
SIMD type for 16-bit signed integral data values.
SIMD type for 32-bit signed integral data values.
SIMD type for 64-bit integral data values.
SIMD type for 16-bit unsigned integral data values.
SIMD type for 32-bit unsigned integral data values.
SIMD type for 64-bit unsigned integral data values.
Complex data type of the Blaze library.
BLAZE_ALWAYS_INLINE const EnableIf_t< IsIntegral_v< T > &&HasSize_v< T, 1UL >, If_t< IsSigned_v< T >, SIMDint8, SIMDuint8 > > setall(T v0, Ts... vs) noexcept
Sets all values in a SIMD vector to the given 1-byte integral values.
Definition Setall.h:153
#define BLAZE_STATIC_ASSERT(expr)
Compile time assertion macro.
Definition StaticAssert.h:112
#define BLAZE_ALWAYS_INLINE
Platform dependent setup of an enforced inline keyword.
Definition Inline.h:85
constexpr bool HasSize_v
Auxiliary variable template for the HasSize type trait.
Definition HasSize.h:171
typename EnableIf< Condition, T >::Type EnableIf_t
Auxiliary type for the EnableIf class template.
Definition EnableIf.h:138
typename If< Condition >::template Type< T1, T2 > If_t
Auxiliary alias template for the If class template.
Definition If.h:108
System settings for the inline keywords.
System settings for the SSE mode.
Header file for basic type definitions.