[cfe-commits] r82228 - /cfe/trunk/lib/Headers/emmintrin.h

Anders Carlsson andersca at mac.com
Fri Sep 18 10:03:55 PDT 2009


Author: andersca
Date: Fri Sep 18 12:03:55 2009
New Revision: 82228

URL: http://llvm.org/viewvc/llvm-project?rev=82228&view=rev
Log:
Fix PR4923.

Fix error in _mm_set_pd/_mm_setr_pd and add _mm_set_epi64x/_mm_set1_epi64x. Patch by Laurent Morichetti!

Modified:
    cfe/trunk/lib/Headers/emmintrin.h

Modified: cfe/trunk/lib/Headers/emmintrin.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Headers/emmintrin.h?rev=82228&r1=82227&r2=82228&view=diff

==============================================================================
--- cfe/trunk/lib/Headers/emmintrin.h (original)
+++ cfe/trunk/lib/Headers/emmintrin.h Fri Sep 18 12:03:55 2009
@@ -500,13 +500,13 @@
 static inline __m128d __attribute__((__always_inline__, __nodebug__))
 _mm_set_pd(double w, double x)
 {
-  return (__m128d){ w, x };
+  return (__m128d){ x, w };
 }
 
 static inline __m128d __attribute__((__always_inline__, __nodebug__))
 _mm_setr_pd(double w, double x)
 {
-  return (__m128d){ x, w };
+  return (__m128d){ w, x };
 }
 
 static inline __m128d __attribute__((__always_inline__, __nodebug__))
@@ -1024,6 +1024,12 @@
 }
 
 static inline __m128i __attribute__((__always_inline__, __nodebug__))
+_mm_set_epi64x(long long q1, long long q0)
+{
+  return (__m128i){ q0, q1 };
+}
+
+static inline __m128i __attribute__((__always_inline__, __nodebug__))
 _mm_set_epi64(__m64 q1, __m64 q0)
 {
   return (__m128i){ (long long)q0, (long long)q1 };
@@ -1048,6 +1054,12 @@
 }
 
 static inline __m128i __attribute__((__always_inline__, __nodebug__))
+_mm_set1_epi64x(long long q)
+{
+  return (__m128i){ q, q };
+}
+
+static inline __m128i __attribute__((__always_inline__, __nodebug__))
 _mm_set1_epi64(__m64 q)
 {
   return (__m128i){ (long long)q, (long long)q };





More information about the cfe-commits mailing list