hasting2 02/12/05 16:04:08 Modified: live/gcc3/gcc/config/i386 xmmintrin.h i386.md Log: Fixes for SSE. Bug #: 3108427, 3108394, 3115800, 3112428 Submitted by: stuart Reviewed by: geoff Revision Changes Path 1.3 +1 -1 src/live/gcc3/gcc/config/i386/xmmintrin.h Index: xmmintrin.h =================================================================== RCS file: /cvs/Darwin/src/live/gcc3/gcc/config/i386/xmmintrin.h,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- xmmintrin.h 2002/12/02 22:58:12 1.2 +++ xmmintrin.h 2002/12/06 00:04:06 1.3 @@ -2075,7 +2075,7 @@ #define _mm_extract_epi16(__A, __B) __builtin_ia32_pextrw128 ((__v8hi)__A, __B) -#define _mm_insert_epi16 (__A, __B, __C) ((__m128i)__builtin_ia32_pinsrw128 ((__v8hi)__A, __B, __C)) +#define _mm_insert_epi16(__A, __B, __C) ((__m128i)__builtin_ia32_pinsrw128 ((__v8hi)__A, __B, __C)) static __inline __m128i _mm_max_epi16 (__m128i __A, __m128i __B) 1.21 +12 -11 src/live/gcc3/gcc/config/i386/i386.md Index: i386.md =================================================================== RCS file: /cvs/Darwin/src/live/gcc3/gcc/config/i386/i386.md,v retrieving revision 1.20 retrieving revision 1.21 diff -u -r1.20 -r1.21 --- i386.md 2002/10/24 23:45:17 1.20 +++ i386.md 2002/12/06 00:04:06 1.21 @@ -1108,14 +1108,15 @@ ; alternative when eax is not available. (define_insn "*movsi_1" - [(set (match_operand:SI 0 "nonimmediate_operand" "=*?a,r,*?a,m,!*y,!rm,!*y,!*Y,!rm,!*Y") - (match_operand:SI 1 "general_operand" "im,rinm,rinm,rin,rm,*y,*y,rm,*Y,*Y"))] + [(set (match_operand:SI 0 "nonimmediate_operand" "=*?a,r ,*?a ,m ,!*y,!rm,!*y,!*Y,!rm,!Y") + (match_operand:SI 1 "general_operand" "im ,rinm,rinm,rin,rm ,*y ,*y ,rm ,*Y ,*Y"))] "GET_CODE (operands[0]) != MEM || GET_CODE (operands[1]) != MEM" { switch (get_attr_type (insn)) { case TYPE_SSEMOV: - if (get_attr_mode (insn) == TImode) + if (get_attr_mode (insn) == TImode + || which_alternative == 9 /* "!Y" and "*Y" case. */ ) return "movdqa\t{%1, %0|%0, %1}"; return "movd\t{%1, %0|%0, %1}"; @@ -18802,7 +18803,7 @@ ;; Use xor, but don't show input operands so they aren't live before ;; this insn. (define_insn "sse_clrv4sf" - [(set (match_operand:V4SF 0 "register_operand" "=x") + [(set (match_operand:V4SF 0 "register_operand" "=y") (unspec:V4SF [(const_int 0)] UNSPEC_NOP))] "TARGET_SSE" "xorps\t{%0, %0|%0, %0}" @@ -21176,7 +21177,7 @@ (define_insn "lshrv8hi3" [(set (match_operand:V8HI 0 "register_operand" "=x") (lshiftrt:V8HI (match_operand:V8HI 1 "register_operand" "0") - (match_operand:SI 2 "nonmemory_operand" "ri")))] + (match_operand:SI 2 "nonmemory_operand" "xi")))] "TARGET_SSE2" "psrlw\t{%2, %0|%0, %2}" [(set_attr "type" "sseishft") @@ -21185,7 +21186,7 @@ (define_insn "lshrv4si3" [(set (match_operand:V4SI 0 "register_operand" "=x") (lshiftrt:V4SI (match_operand:V4SI 1 "register_operand" "0") - (match_operand:SI 2 "nonmemory_operand" "ri")))] + (match_operand:SI 2 "nonmemory_operand" "xi")))] "TARGET_SSE2" "psrld\t{%2, %0|%0, %2}" [(set_attr "type" "sseishft") @@ -21194,7 +21195,7 @@ (define_insn "lshrv2di3" [(set (match_operand:V2DI 0 "register_operand" "=x") (lshiftrt:V2DI (match_operand:V2DI 1 "register_operand" "0") - (match_operand:SI 2 "nonmemory_operand" "ri")))] + (match_operand:SI 2 "nonmemory_operand" "xi")))] "TARGET_SSE2" "psrlq\t{%2, %0|%0, %2}" [(set_attr "type" "sseishft") @@ -21203,7 +21204,7 @@ (define_insn "ashlv8hi3" [(set (match_operand:V8HI 0 "register_operand" "=x") (ashift:V8HI (match_operand:V8HI 1 "register_operand" "0") - (match_operand:SI 2 "nonmemory_operand" "ri")))] + (match_operand:SI 2 "nonmemory_operand" "xi")))] "TARGET_SSE2" "psllw\t{%2, %0|%0, %2}" [(set_attr "type" "sseishft") @@ -21212,7 +21213,7 @@ (define_insn "ashlv4si3" [(set (match_operand:V4SI 0 "register_operand" "=x") (ashift:V4SI (match_operand:V4SI 1 "register_operand" "0") - (match_operand:SI 2 "nonmemory_operand" "ri")))] + (match_operand:SI 2 "nonmemory_operand" "xi")))] "TARGET_SSE2" "pslld\t{%2, %0|%0, %2}" [(set_attr "type" "sseishft") @@ -21221,7 +21222,7 @@ (define_insn "ashlv2di3" [(set (match_operand:V2DI 0 "register_operand" "=x") (ashift:V2DI (match_operand:V2DI 1 "register_operand" "0") - (match_operand:SI 2 "nonmemory_operand" "ri")))] + (match_operand:SI 2 "nonmemory_operand" "xi")))] "TARGET_SSE2" "psllq\t{%2, %0|%0, %2}" [(set_attr "type" "sseishft") @@ -21321,7 +21322,7 @@ (mult:SI (match_operand:SI 2 "immediate_operand" "i") (const_int 8)))] UNSPEC_NOP))] "TARGET_SSE2" - "pslrdq\t{%2, %0|%0, %2}" + "psrldq\t{%2, %0|%0, %2}" [(set_attr "type" "sseishft") (set_attr "mode" "TI")])