diff options
author | Jan Hubicka <jh@suse.cz> | 2001-02-27 15:54:15 +0100 |
---|---|---|
committer | Jan Hubicka <hubicka@gcc.gnu.org> | 2001-02-27 14:54:15 +0000 |
commit | 79005df529ad1071e5f0f512fb4d63ec817c4935 (patch) | |
tree | 18eaa8c3247a7ac379c1b976c779ca82124a1eef | |
parent | 7ada6625cd3a7e6940248cbb4e60a7e68b3b7f12 (diff) | |
download | gcc-79005df529ad1071e5f0f512fb4d63ec817c4935.zip gcc-79005df529ad1071e5f0f512fb4d63ec817c4935.tar.gz gcc-79005df529ad1071e5f0f512fb4d63ec817c4935.tar.bz2 |
i386.md (movsf, movdf): Use movaps for reg-reg moves if TARGET_PARTIAL_REG_DEPENDENCY.
* i386.md (movsf, movdf): Use movaps for reg-reg moves if
TARGET_PARTIAL_REG_DEPENDENCY.
(truncdfsf2_1_sse, truncdfsf2_2): Penalize the fpreg->mem case.
From-SVN: r40093
-rw-r--r-- | gcc/ChangeLog | 6 | ||||
-rw-r--r-- | gcc/config/i386/i386.md | 26 |
2 files changed, 23 insertions, 9 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index c8eeca6..1546b80 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +Tue Feb 27 15:51:35 CET 2001 Jan Hubicka <jh@suse.cz> + + * i386.md (movsf, movdf): Use movaps for reg-reg moves if + TARGET_PARTIAL_REG_DEPENDENCY. + (truncdfsf2_1_sse, truncdfsf2_2): Penalize the fpreg->mem case. + Tue Feb 27 15:36:48 CET 2001 Jan Hubicka <jh@suse.cz> * i386.md (mins*, maxs*): New patterns, expanders and splitters. diff --git a/gcc/config/i386/i386.md b/gcc/config/i386/i386.md index de36912..25a283f 100644 --- a/gcc/config/i386/i386.md +++ b/gcc/config/i386/i386.md @@ -2238,6 +2238,10 @@ return \"mov{l}\\t{%1, %0|%0, %1}\"; case 5: case 6: + if (TARGET_PARTIAL_REG_DEPENDENCY + && register_operand (operands[0], VOIDmode) + && register_operand (operands[1], VOIDmode)) + return \"movaps\\t{%1, %0|%0, %1}\"; return \"movss\\t{%1, %0|%0, %1}\"; default: @@ -2412,6 +2416,10 @@ return \"#\"; case 5: case 6: + if (TARGET_PARTIAL_REG_DEPENDENCY + && register_operand (operands[0], VOIDmode) + && register_operand (operands[1], VOIDmode)) + return \"movapd\\t{%1, %0|%0, %1}\"; return \"movsd\\t{%1, %0|%0, %1}\"; default: @@ -3626,7 +3634,7 @@ (set_attr "mode" "SF,SF")]) (define_insn "*truncdfsf2_1_sse" - [(set (match_operand:SF 0 "nonimmediate_operand" "=m,?f,Y") + [(set (match_operand:SF 0 "nonimmediate_operand" "=*!m,?f,Y") (float_truncate:SF (match_operand:DF 1 "nonimmediate_operand" "f,0,mY"))) (clobber (match_operand:SF 2 "memory_operand" "=X,m,X"))] @@ -3652,26 +3660,26 @@ (set_attr "mode" "SF,SF,DF")]) (define_insn "*truncdfsf2_2" - [(set (match_operand:SF 0 "nonimmediate_operand" "=m,Y") + [(set (match_operand:SF 0 "nonimmediate_operand" "=Y,!m") (float_truncate:SF - (match_operand:DF 1 "nonimmediate_operand" "f,mY")))] - "TARGET_80387 && TARGET_SSE2" + (match_operand:DF 1 "nonimmediate_operand" "mY,f")))] + "TARGET_80387 && TARGET_SSE2 + && (GET_CODE (operands[0]) != MEM || GET_CODE (operands[1]) != MEM)" "* { switch (which_alternative) { case 0: + return \"cvtsd2ss\\t{%1, %0|%0, %1}\"; + case 1: if (find_regno_note (insn, REG_DEAD, REGNO (operands[1]))) return \"fstp%z0\\t%y0\"; else return \"fst%z0\\t%y0\"; - case 1: - case 2: - return \"cvtsd2ss\\t{%1, %0|%0, %1}\"; } }" - [(set_attr "type" "fmov,sse") - (set_attr "mode" "SF,DF")]) + [(set_attr "type" "sse,fmov") + (set_attr "mode" "DF,SF")]) (define_insn "truncdfsf2_3" [(set (match_operand:SF 0 "nonimmediate_operand" "=m") |