r252697 - [X86] Change pointer type in AVX2 gather builtins to be the scalar type instead of the vector type. This matches gcc and removes extras casts.

Craig Topper via cfe-commits cfe-commits at lists.llvm.org
Tue Nov 10 18:51:18 PST 2015


Author: ctopper
Date: Tue Nov 10 20:51:18 2015
New Revision: 252697

URL: http://llvm.org/viewvc/llvm-project?rev=252697&view=rev
Log:
[X86] Change pointer type in AVX2 gather builtins to be the scalar type instead of the vector type. This matches gcc and removes extras casts.

Modified:
    cfe/trunk/include/clang/Basic/BuiltinsX86.def
    cfe/trunk/lib/Headers/avx2intrin.h

Modified: cfe/trunk/include/clang/Basic/BuiltinsX86.def
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Basic/BuiltinsX86.def?rev=252697&r1=252696&r2=252697&view=diff
==============================================================================
--- cfe/trunk/include/clang/Basic/BuiltinsX86.def (original)
+++ cfe/trunk/include/clang/Basic/BuiltinsX86.def Tue Nov 10 20:51:18 2015
@@ -618,23 +618,23 @@ TARGET_BUILTIN(__builtin_ia32_psrlv4di,
 TARGET_BUILTIN(__builtin_ia32_psrlv2di, "V2LLiV2LLiV2LLi", "", "avx2")
 
 // GATHER
-TARGET_BUILTIN(__builtin_ia32_gatherd_pd, "V2dV2dV2dC*V4iV2dIc", "", "avx2")
-TARGET_BUILTIN(__builtin_ia32_gatherd_pd256, "V4dV4dV4dC*V4iV4dIc", "", "avx2")
-TARGET_BUILTIN(__builtin_ia32_gatherq_pd, "V2dV2dV2dC*V2LLiV2dIc", "", "avx2")
-TARGET_BUILTIN(__builtin_ia32_gatherq_pd256, "V4dV4dV4dC*V4LLiV4dIc", "", "avx2")
-TARGET_BUILTIN(__builtin_ia32_gatherd_ps, "V4fV4fV4fC*V4iV4fIc", "", "avx2")
-TARGET_BUILTIN(__builtin_ia32_gatherd_ps256, "V8fV8fV8fC*V8iV8fIc", "", "avx2")
-TARGET_BUILTIN(__builtin_ia32_gatherq_ps, "V4fV4fV4fC*V2LLiV4fIc", "", "avx2")
-TARGET_BUILTIN(__builtin_ia32_gatherq_ps256, "V4fV4fV4fC*V4LLiV4fIc", "", "avx2")
+TARGET_BUILTIN(__builtin_ia32_gatherd_pd, "V2dV2ddC*V4iV2dIc", "", "avx2")
+TARGET_BUILTIN(__builtin_ia32_gatherd_pd256, "V4dV4ddC*V4iV4dIc", "", "avx2")
+TARGET_BUILTIN(__builtin_ia32_gatherq_pd, "V2dV2ddC*V2LLiV2dIc", "", "avx2")
+TARGET_BUILTIN(__builtin_ia32_gatherq_pd256, "V4dV4ddC*V4LLiV4dIc", "", "avx2")
+TARGET_BUILTIN(__builtin_ia32_gatherd_ps, "V4fV4ffC*V4iV4fIc", "", "avx2")
+TARGET_BUILTIN(__builtin_ia32_gatherd_ps256, "V8fV8ffC*V8iV8fIc", "", "avx2")
+TARGET_BUILTIN(__builtin_ia32_gatherq_ps, "V4fV4ffC*V2LLiV4fIc", "", "avx2")
+TARGET_BUILTIN(__builtin_ia32_gatherq_ps256, "V4fV4ffC*V4LLiV4fIc", "", "avx2")
 
-TARGET_BUILTIN(__builtin_ia32_gatherd_q, "V2LLiV2LLiV2LLiC*V4iV2LLiIc", "", "avx2")
-TARGET_BUILTIN(__builtin_ia32_gatherd_q256, "V4LLiV4LLiV4LLiC*V4iV4LLiIc", "", "avx2")
-TARGET_BUILTIN(__builtin_ia32_gatherq_q, "V2LLiV2LLiV2LLiC*V2LLiV2LLiIc", "", "avx2")
-TARGET_BUILTIN(__builtin_ia32_gatherq_q256, "V4LLiV4LLiV4LLiC*V4LLiV4LLiIc", "", "avx2")
-TARGET_BUILTIN(__builtin_ia32_gatherd_d, "V4iV4iV4iC*V4iV4iIc", "", "avx2")
-TARGET_BUILTIN(__builtin_ia32_gatherd_d256, "V8iV8iV8iC*V8iV8iIc", "", "avx2")
-TARGET_BUILTIN(__builtin_ia32_gatherq_d, "V4iV4iV4iC*V2LLiV4iIc", "", "avx2")
-TARGET_BUILTIN(__builtin_ia32_gatherq_d256, "V4iV4iV4iC*V4LLiV4iIc", "", "avx2")
+TARGET_BUILTIN(__builtin_ia32_gatherd_q, "V2LLiV2LLiLLiC*V4iV2LLiIc", "", "avx2")
+TARGET_BUILTIN(__builtin_ia32_gatherd_q256, "V4LLiV4LLiLLiC*V4iV4LLiIc", "", "avx2")
+TARGET_BUILTIN(__builtin_ia32_gatherq_q, "V2LLiV2LLiLLiC*V2LLiV2LLiIc", "", "avx2")
+TARGET_BUILTIN(__builtin_ia32_gatherq_q256, "V4LLiV4LLiLLiC*V4LLiV4LLiIc", "", "avx2")
+TARGET_BUILTIN(__builtin_ia32_gatherd_d, "V4iV4iiC*V4iV4iIc", "", "avx2")
+TARGET_BUILTIN(__builtin_ia32_gatherd_d256, "V8iV8iiC*V8iV8iIc", "", "avx2")
+TARGET_BUILTIN(__builtin_ia32_gatherq_d, "V4iV4iiC*V2LLiV4iIc", "", "avx2")
+TARGET_BUILTIN(__builtin_ia32_gatherq_d256, "V4iV4iiC*V4LLiV4iIc", "", "avx2")
 
 // F16C
 TARGET_BUILTIN(__builtin_ia32_vcvtps2ph, "V8sV4fIi", "", "f16c")

Modified: cfe/trunk/lib/Headers/avx2intrin.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Headers/avx2intrin.h?rev=252697&r1=252696&r2=252697&view=diff
==============================================================================
--- cfe/trunk/lib/Headers/avx2intrin.h (original)
+++ cfe/trunk/lib/Headers/avx2intrin.h Tue Nov 10 20:51:18 2015
@@ -1006,244 +1006,202 @@ _mm_srlv_epi64(__m128i __X, __m128i __Y)
 }
 
 #define _mm_mask_i32gather_pd(a, m, i, mask, s) __extension__ ({ \
-  __m128d __a = (a); \
-  double const *__m = (m); \
-  __m128i __i = (i); \
-  __m128d __mask = (mask); \
-  (__m128d)__builtin_ia32_gatherd_pd((__v2df)__a, (const __v2df *)__m, \
-             (__v4si)__i, (__v2df)__mask, (s)); })
+  (__m128d)__builtin_ia32_gatherd_pd((__v2df)(__m128i)(a), \
+                                     (double const *)(m), \
+                                     (__v4si)(__m128i)(i), \
+                                     (__v2df)(__m128d)(mask), (s)); })
 
 #define _mm256_mask_i32gather_pd(a, m, i, mask, s) __extension__ ({ \
-  __m256d __a = (a); \
-  double const *__m = (m); \
-  __m128i __i = (i); \
-  __m256d __mask = (mask); \
-  (__m256d)__builtin_ia32_gatherd_pd256((__v4df)__a, (const __v4df *)__m, \
-             (__v4si)__i, (__v4df)__mask, (s)); })
+  (__m256d)__builtin_ia32_gatherd_pd256((__v4df)(__m256d)(a), \
+                                        (double const *)(m), \
+                                        (__v4si)(__m128i)(i), \
+                                        (__v4df)(__m256d)(mask), (s)); })
 
 #define _mm_mask_i64gather_pd(a, m, i, mask, s) __extension__ ({ \
-  __m128d __a = (a); \
-  double const *__m = (m); \
-  __m128i __i = (i); \
-  __m128d __mask = (mask); \
-  (__m128d)__builtin_ia32_gatherq_pd((__v2df)__a, (const __v2df *)__m, \
-             (__v2di)__i, (__v2df)__mask, (s)); })
+  (__m128d)__builtin_ia32_gatherq_pd((__v2df)(__m128d)(a), \
+                                     (double const *)(m), \
+                                     (__v2di)(__m128i)(i), \
+                                     (__v2df)(__m128d)(mask), (s)); })
 
 #define _mm256_mask_i64gather_pd(a, m, i, mask, s) __extension__ ({ \
-  __m256d __a = (a); \
-  double const *__m = (m); \
-  __m256i __i = (i); \
-  __m256d __mask = (mask); \
-  (__m256d)__builtin_ia32_gatherq_pd256((__v4df)__a, (const __v4df *)__m, \
-             (__v4di)__i, (__v4df)__mask, (s)); })
+  (__m256d)__builtin_ia32_gatherq_pd256((__v4df)(__m256d)(a), \
+                                        (double const *)(m), \
+                                        (__v4di)(__m256i)(i), \
+                                        (__v4df)(__m256d)(mask), (s)); })
 
 #define _mm_mask_i32gather_ps(a, m, i, mask, s) __extension__ ({ \
-  __m128 __a = (a); \
-  float const *__m = (m); \
-  __m128i __i = (i); \
-  __m128 __mask = (mask); \
-  (__m128)__builtin_ia32_gatherd_ps((__v4sf)__a, (const __v4sf *)__m, \
-            (__v4si)__i, (__v4sf)__mask, (s)); })
+  (__m128)__builtin_ia32_gatherd_ps((__v4sf)(__m128)(a), \
+                                    (float const *)(m), \
+                                    (__v4si)(__m128i)(i), \
+                                    (__v4sf)(__m128)(mask), (s)); })
 
 #define _mm256_mask_i32gather_ps(a, m, i, mask, s) __extension__ ({ \
-  __m256 __a = (a); \
-  float const *__m = (m); \
-  __m256i __i = (i); \
-  __m256 __mask = (mask); \
-  (__m256)__builtin_ia32_gatherd_ps256((__v8sf)__a, (const __v8sf *)__m, \
-            (__v8si)__i, (__v8sf)__mask, (s)); })
+  (__m256)__builtin_ia32_gatherd_ps256((__v8sf)(__m256)(a), \
+                                       (float const *)(m), \
+                                       (__v8si)(__m256i)(i), \
+                                       (__v8sf)(__m256)(mask), (s)); })
 
 #define _mm_mask_i64gather_ps(a, m, i, mask, s) __extension__ ({ \
-  __m128 __a = (a); \
-  float const *__m = (m); \
-  __m128i __i = (i); \
-  __m128 __mask = (mask); \
-  (__m128)__builtin_ia32_gatherq_ps((__v4sf)__a, (const __v4sf *)__m, \
-            (__v2di)__i, (__v4sf)__mask, (s)); })
+  (__m128)__builtin_ia32_gatherq_ps((__v4sf)(__m128)(a), \
+                                    (float const *)(m), \
+                                    (__v2di)(__m128i)(i), \
+                                    (__v4sf)(__m128)(mask), (s)); })
 
 #define _mm256_mask_i64gather_ps(a, m, i, mask, s) __extension__ ({ \
-  __m128 __a = (a); \
-  float const *__m = (m); \
-  __m256i __i = (i); \
-  __m128 __mask = (mask); \
-  (__m128)__builtin_ia32_gatherq_ps256((__v4sf)__a, (const __v4sf *)__m, \
-            (__v4di)__i, (__v4sf)__mask, (s)); })
+  (__m128)__builtin_ia32_gatherq_ps256((__v4sf)(__m128)(a), \
+                                       (float const *)(m), \
+                                       (__v4di)(__m256i)(i), \
+                                       (__v4sf)(__m128)(mask), (s)); })
 
 #define _mm_mask_i32gather_epi32(a, m, i, mask, s) __extension__ ({ \
-  __m128i __a = (a); \
-  int const *__m = (m); \
-  __m128i __i = (i); \
-  __m128i __mask = (mask); \
-  (__m128i)__builtin_ia32_gatherd_d((__v4si)__a, (const __v4si *)__m, \
-            (__v4si)__i, (__v4si)__mask, (s)); })
+  (__m128i)__builtin_ia32_gatherd_d((__v4si)(__m128i)(a), \
+                                    (int const *)(m), \
+                                    (__v4si)(__m128i)(i), \
+                                    (__v4si)(__m128i)(mask), (s)); })
 
 #define _mm256_mask_i32gather_epi32(a, m, i, mask, s) __extension__ ({ \
-  __m256i __a = (a); \
-  int const *__m = (m); \
-  __m256i __i = (i); \
-  __m256i __mask = (mask); \
-  (__m256i)__builtin_ia32_gatherd_d256((__v8si)__a, (const __v8si *)__m, \
-            (__v8si)__i, (__v8si)__mask, (s)); })
+  (__m256i)__builtin_ia32_gatherd_d256((__v8si)(__m256i)(a), \
+                                       (int const *)(m), \
+                                       (__v8si)(__m256i)(i), \
+                                       (__v8si)(__m256i)(mask), (s)); })
 
 #define _mm_mask_i64gather_epi32(a, m, i, mask, s) __extension__ ({ \
-  __m128i __a = (a); \
-  int const *__m = (m); \
-  __m128i __i = (i); \
-  __m128i __mask = (mask); \
-  (__m128i)__builtin_ia32_gatherq_d((__v4si)__a, (const __v4si *)__m, \
-            (__v2di)__i, (__v4si)__mask, (s)); })
+  (__m128i)__builtin_ia32_gatherq_d((__v4si)(__m128i)(a), \
+                                    (int const *)(m), \
+                                    (__v2di)(__m128i)(i), \
+                                    (__v4si)(__m128i)(mask), (s)); })
 
 #define _mm256_mask_i64gather_epi32(a, m, i, mask, s) __extension__ ({ \
-  __m128i __a = (a); \
-  int const *__m = (m); \
-  __m256i __i = (i); \
-  __m128i __mask = (mask); \
-  (__m128i)__builtin_ia32_gatherq_d256((__v4si)__a, (const __v4si *)__m, \
-            (__v4di)__i, (__v4si)__mask, (s)); })
+  (__m128i)__builtin_ia32_gatherq_d256((__v4si)(__m128i)(a), \
+                                       (int const *)(m), \
+                                       (__v4di)(__m256i)(i), \
+                                       (__v4si)(__m128i)(mask), (s)); })
 
 #define _mm_mask_i32gather_epi64(a, m, i, mask, s) __extension__ ({ \
-  __m128i __a = (a); \
-  long long const *__m = (m); \
-  __m128i __i = (i); \
-  __m128i __mask = (mask); \
-  (__m128i)__builtin_ia32_gatherd_q((__v2di)__a, (const __v2di *)__m, \
-             (__v4si)__i, (__v2di)__mask, (s)); })
+  (__m128i)__builtin_ia32_gatherd_q((__v2di)(__m128i)(a), \
+                                    (long long const *)(m), \
+                                    (__v4si)(__m128i)(i), \
+                                    (__v2di)(__m128i)(mask), (s)); })
 
 #define _mm256_mask_i32gather_epi64(a, m, i, mask, s) __extension__ ({ \
-  __m256i __a = (a); \
-  long long const *__m = (m); \
-  __m128i __i = (i); \
-  __m256i __mask = (mask); \
-  (__m256i)__builtin_ia32_gatherd_q256((__v4di)__a, (const __v4di *)__m, \
-             (__v4si)__i, (__v4di)__mask, (s)); })
+  (__m256i)__builtin_ia32_gatherd_q256((__v4di)(__m256i)(a), \
+                                       (long long const *)(m), \
+                                       (__v4si)(__m128i)(i), \
+                                       (__v4di)(__m256i)(mask), (s)); })
 
 #define _mm_mask_i64gather_epi64(a, m, i, mask, s) __extension__ ({ \
-  __m128i __a = (a); \
-  long long const *__m = (m); \
-  __m128i __i = (i); \
-  __m128i __mask = (mask); \
-  (__m128i)__builtin_ia32_gatherq_q((__v2di)__a, (const __v2di *)__m, \
-             (__v2di)__i, (__v2di)__mask, (s)); })
+  (__m128i)__builtin_ia32_gatherq_q((__v2di)(__m128i)(a), \
+                                    (long long const *)(m), \
+                                    (__v2di)(__m128i)(i), \
+                                    (__v2di)(__m128i)(mask), (s)); })
 
 #define _mm256_mask_i64gather_epi64(a, m, i, mask, s) __extension__ ({ \
-  __m256i __a = (a); \
-  long long const *__m = (m); \
-  __m256i __i = (i); \
-  __m256i __mask = (mask); \
-  (__m256i)__builtin_ia32_gatherq_q256((__v4di)__a, (const __v4di *)__m, \
-             (__v4di)__i, (__v4di)__mask, (s)); })
+  (__m256i)__builtin_ia32_gatherq_q256((__v4di)(__m256i)(a), \
+                                       (long long const *)(m), \
+                                       (__v4di)(__m256i)(i), \
+                                       (__v4di)(__m256i)(mask), (s)); })
 
 #define _mm_i32gather_pd(m, i, s) __extension__ ({ \
-  double const *__m = (m); \
-  __m128i __i = (i); \
   (__m128d)__builtin_ia32_gatherd_pd((__v2df)_mm_setzero_pd(), \
-             (const __v2df *)__m, (__v4si)__i, \
-             (__v2df)_mm_set1_pd((double)(long long int)-1), (s)); })
+                                     (double const *)(m), \
+                                     (__v4si)(__m128i)(i), \
+                                     (__v2df)_mm_set1_pd( \
+                                       (double)(long long int)-1), \
+                                     (s)); })
 
 #define _mm256_i32gather_pd(m, i, s) __extension__ ({ \
-  double const *__m = (m); \
-  __m128i __i = (i); \
   (__m256d)__builtin_ia32_gatherd_pd256((__v4df)_mm256_setzero_pd(), \
-             (const __v4df *)__m, (__v4si)__i, \
-             (__v4df)_mm256_set1_pd((double)(long long int)-1), (s)); })
+                                        (double const *)(m), \
+                                        (__v4si)(__m128i)(i), \
+                                        (__v4df)_mm256_set1_pd( \
+                                          (double)(long long int)-1), \
+                                        (s)); })
 
 #define _mm_i64gather_pd(m, i, s) __extension__ ({ \
-  double const *__m = (m); \
-  __m128i __i = (i); \
   (__m128d)__builtin_ia32_gatherq_pd((__v2df)_mm_setzero_pd(), \
-             (const __v2df *)__m, (__v2di)__i, \
-             (__v2df)_mm_set1_pd((double)(long long int)-1), (s)); })
+                                     (double const *)(m), \
+                                     (__v2di)(__m128i)(i), \
+                                     (__v2df)_mm_set1_pd( \
+                                       (double)(long long int)-1), \
+                                     (s)); })
 
 #define _mm256_i64gather_pd(m, i, s) __extension__ ({ \
-  double const *__m = (m); \
-  __m256i __i = (i); \
   (__m256d)__builtin_ia32_gatherq_pd256((__v4df)_mm256_setzero_pd(), \
-             (const __v4df *)__m, (__v4di)__i, \
-             (__v4df)_mm256_set1_pd((double)(long long int)-1), (s)); })
+                                        (double const *)(m), \
+                                        (__v4di)(__m256i)(i), \
+                                        (__v4df)_mm256_set1_pd( \
+                                          (double)(long long int)-1), \
+                                        (s)); })
 
 #define _mm_i32gather_ps(m, i, s) __extension__ ({ \
-  float const *__m = (m); \
-  __m128i __i = (i); \
   (__m128)__builtin_ia32_gatherd_ps((__v4sf)_mm_setzero_ps(), \
-             (const __v4sf *)__m, (__v4si)__i, \
-             (__v4sf)_mm_set1_ps((float)(int)-1), (s)); })
+                                    (float const *)(m), (__v4si)(__m128i)(i), \
+                                    (__v4sf)_mm_set1_ps((float)(int)-1), \
+                                    (s)); })
 
 #define _mm256_i32gather_ps(m, i, s) __extension__ ({ \
-  float const *__m = (m); \
-  __m256i __i = (i); \
   (__m256)__builtin_ia32_gatherd_ps256((__v8sf)_mm256_setzero_ps(), \
-             (const __v8sf *)__m, (__v8si)__i, \
-             (__v8sf)_mm256_set1_ps((float)(int)-1), (s)); })
+                                       (float const *)(m), \
+                                       (__v8si)(__m256i)(i), \
+                                       (__v8sf)_mm256_set1_ps((float)(int)-1), \
+                                       (s)); })
 
 #define _mm_i64gather_ps(m, i, s) __extension__ ({ \
-  float const *__m = (m); \
-  __m128i __i = (i); \
   (__m128)__builtin_ia32_gatherq_ps((__v4sf)_mm_setzero_ps(), \
-             (const __v4sf *)__m, (__v2di)__i, \
-             (__v4sf)_mm_set1_ps((float)(int)-1), (s)); })
+                                    (float const *)(m), (__v2di)(__m128i)(i), \
+                                    (__v4sf)_mm_set1_ps((float)(int)-1), \
+                                    (s)); })
 
 #define _mm256_i64gather_ps(m, i, s) __extension__ ({ \
-  float const *__m = (m); \
-  __m256i __i = (i); \
   (__m128)__builtin_ia32_gatherq_ps256((__v4sf)_mm_setzero_ps(), \
-             (const __v4sf *)__m, (__v4di)__i, \
-             (__v4sf)_mm_set1_ps((float)(int)-1), (s)); })
+                                       (float const *)(m), \
+                                       (__v4di)(__m256i)(i), \
+                                       (__v4sf)_mm_set1_ps((float)(int)-1), \
+                                       (s)); })
 
 #define _mm_i32gather_epi32(m, i, s) __extension__ ({ \
-  int const *__m = (m); \
-  __m128i __i = (i); \
   (__m128i)__builtin_ia32_gatherd_d((__v4si)_mm_setzero_si128(), \
-            (const __v4si *)__m, (__v4si)__i, \
-            (__v4si)_mm_set1_epi32(-1), (s)); })
+                                    (int const *)(m), (__v4si)(__m128i)(i), \
+                                    (__v4si)_mm_set1_epi32(-1), (s)); })
 
 #define _mm256_i32gather_epi32(m, i, s) __extension__ ({ \
-  int const *__m = (m); \
-  __m256i __i = (i); \
   (__m256i)__builtin_ia32_gatherd_d256((__v8si)_mm256_setzero_si256(), \
-            (const __v8si *)__m, (__v8si)__i, \
-            (__v8si)_mm256_set1_epi32(-1), (s)); })
+                                       (int const *)(m), (__v8si)(__m256i)(i), \
+                                       (__v8si)_mm256_set1_epi32(-1), (s)); })
 
 #define _mm_i64gather_epi32(m, i, s) __extension__ ({ \
-  int const *__m = (m); \
-  __m128i __i = (i); \
   (__m128i)__builtin_ia32_gatherq_d((__v4si)_mm_setzero_si128(), \
-            (const __v4si *)__m, (__v2di)__i, \
-            (__v4si)_mm_set1_epi32(-1), (s)); })
+                                    (int const *)(m), (__v2di)(__m128i)(i), \
+                                    (__v4si)_mm_set1_epi32(-1), (s)); })
 
 #define _mm256_i64gather_epi32(m, i, s) __extension__ ({ \
-  int const *__m = (m); \
-  __m256i __i = (i); \
   (__m128i)__builtin_ia32_gatherq_d256((__v4si)_mm_setzero_si128(), \
-            (const __v4si *)__m, (__v4di)__i, \
-            (__v4si)_mm_set1_epi32(-1), (s)); })
+                                       (int const *)(m), (__v4di)(__m256i)(i), \
+                                       (__v4si)_mm_set1_epi32(-1), (s)); })
 
 #define _mm_i32gather_epi64(m, i, s) __extension__ ({ \
-  long long const *__m = (m); \
-  __m128i __i = (i); \
   (__m128i)__builtin_ia32_gatherd_q((__v2di)_mm_setzero_si128(), \
-             (const __v2di *)__m, (__v4si)__i, \
-             (__v2di)_mm_set1_epi64x(-1), (s)); })
+                                    (long long const *)(m), \
+                                    (__v4si)(__m128i)(i), \
+                                    (__v2di)_mm_set1_epi64x(-1), (s)); })
 
 #define _mm256_i32gather_epi64(m, i, s) __extension__ ({ \
-  long long const *__m = (m); \
-  __m128i __i = (i); \
   (__m256i)__builtin_ia32_gatherd_q256((__v4di)_mm256_setzero_si256(), \
-             (const __v4di *)__m, (__v4si)__i, \
-             (__v4di)_mm256_set1_epi64x(-1), (s)); })
+                                       (long long const *)(m), \
+                                       (__v4si)(__m128i)(i), \
+                                       (__v4di)_mm256_set1_epi64x(-1), (s)); })
 
 #define _mm_i64gather_epi64(m, i, s) __extension__ ({ \
-  long long const *__m = (m); \
-  __m128i __i = (i); \
   (__m128i)__builtin_ia32_gatherq_q((__v2di)_mm_setzero_si128(), \
-             (const __v2di *)__m, (__v2di)__i, \
-             (__v2di)_mm_set1_epi64x(-1), (s)); })
+                                    (long long const *)(m), \
+                                    (__v2di)(__m128i)(i), \
+                                    (__v2di)_mm_set1_epi64x(-1), (s)); })
 
 #define _mm256_i64gather_epi64(m, i, s) __extension__ ({ \
-  long long const *__m = (m); \
-  __m256i __i = (i); \
   (__m256i)__builtin_ia32_gatherq_q256((__v4di)_mm256_setzero_si256(), \
-             (const __v4di *)__m, (__v4di)__i, \
-             (__v4di)_mm256_set1_epi64x(-1), (s)); })
+                                       (long long const *)(m), \
+                                       (__v4di)(__m256i)(i), \
+                                       (__v4di)_mm256_set1_epi64x(-1), (s)); })
 
 #undef __DEFAULT_FN_ATTRS
 




More information about the cfe-commits mailing list