This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

SSE "fix" 24 - integer comparsions


Hi,
this patch adds few variants of integer comparsions. These are not
specified in Intel documentation, but both commercial compilers I can
tests accepts them so people are using it.  I don't se reason why we
can't.

Tue Oct 22 23:28:12 CEST 2002  Jan Hubicka  <jh@suse.cz>
	* xmmintrin.h (_mm_cmplt_epi*): New.
Index: xmmintrin.h
===================================================================
RCS file: /cvs/gcc/egcs/gcc/config/i386/xmmintrin.h,v
retrieving revision 1.15
diff -c -3 -p -r1.15 xmmintrin.h
*** xmmintrin.h	22 Oct 2002 17:08:42 -0000	1.15
--- xmmintrin.h	22 Oct 2002 21:27:42 -0000
*************** _mm_cmpeq_epi32 (__m128i __A, __m128i __
*** 2308,2313 ****
--- 2308,2331 ----
  }
  
  static __inline __m128i
+ _mm_cmplt_epi8 (__m128i __A, __m128i __B)
+ {
+   return (__m128i)__builtin_ia32_pcmpgtb128 ((__v16qi)__B, (__v16qi)__A);
+ }
+ 
+ static __inline __m128i
+ _mm_cmplt_epi16 (__m128i __A, __m128i __B)
+ {
+   return (__m128i)__builtin_ia32_pcmpgtw128 ((__v8hi)__B, (__v8hi)__A);
+ }
+ 
+ static __inline __m128i
+ _mm_cmplt_epi32 (__m128i __A, __m128i __B)
+ {
+   return (__m128i)__builtin_ia32_pcmpgtd128 ((__v4si)__B, (__v4si)__A);
+ }
+ 
+ static __inline __m128i
  _mm_cmpgt_epi8 (__m128i __A, __m128i __B)
  {
    return (__m128i)__builtin_ia32_pcmpgtb128 ((__v16qi)__A, (__v16qi)__B);


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]