diff options
author | Jan Hubicka <hubicka@freesoft.cz> | 1999-04-14 01:39:22 +0200 |
---|---|---|
committer | Jeff Law <law@gcc.gnu.org> | 1999-04-13 17:39:22 -0600 |
commit | c0b9be67989328e0ad6141537da0fd04972a4317 (patch) | |
tree | 12a2a674198462af2bd6dce3781800965ec3fc48 /gcc | |
parent | fb693d4449e4997e2e26549313ef6115bc41d629 (diff) | |
download | gcc-c0b9be67989328e0ad6141537da0fd04972a4317.zip gcc-c0b9be67989328e0ad6141537da0fd04972a4317.tar.gz gcc-c0b9be67989328e0ad6141537da0fd04972a4317.tar.bz2 |
i386.md (neghi2): Do not output prefixed opcode when possible.
* i386.md (neghi2): Do not output prefixed opcode when possible.
(ashlhi3): Likewise.
From-SVN: r26433
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/config/i386/i386.md | 31 |
2 files changed, 33 insertions, 3 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index f1c5773..1d0c6e7 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +Wed Apr 14 00:18:22 1999 Jan Hubicka <hubicka@freesoft.cz> + + * i386.md (neghi2): Do not output prefixed opcode when possible. + (ashlhi3): Likewise. + Wed Apr 14 00:08:46 1999 Richard Henderson <rth@cygnus.com> * i386.c (memory_address_length): New function. diff --git a/gcc/config/i386/i386.md b/gcc/config/i386/i386.md index f54565e..2701724 100644 --- a/gcc/config/i386/i386.md +++ b/gcc/config/i386/i386.md @@ -4721,7 +4721,13 @@ byte_xor_operation: [(set (match_operand:HI 0 "nonimmediate_operand" "=rm") (neg:HI (match_operand:HI 1 "nonimmediate_operand" "0")))] "" - "neg%W0 %0") + "* + if (REG_P (operands[0]) && i386_cc_probably_useless_p (insn)) + { + CC_STATUS_INIT; + return AS1(neg%L0,%0); + } + return AS1(neg%W0,%0);") (define_insn "negqi2" [(set (match_operand:QI 0 "nonimmediate_operand" "=qm") @@ -5053,11 +5059,30 @@ byte_xor_operation: "* { if (REG_P (operands[2])) - return AS2 (sal%W0,%b2,%0); + { + if (REG_P (operands[0]) && i386_cc_probably_useless_p (insn)) + { + CC_STATUS_INIT; + return AS2 (sal%L0,%b2,%k0); + } + return AS2 (sal%W0,%b2,%0); + } if (REG_P (operands[0]) && operands[2] == const1_rtx) - return AS2 (add%W0,%0,%0); + { + if (i386_cc_probably_useless_p (insn)) + { + CC_STATUS_INIT; + return AS2 (add%L0,%k0,%k0); + } + return AS2 (add%W0,%0,%0); + } + if (REG_P (operands[0]) && i386_cc_probably_useless_p (insn)) + { + CC_STATUS_INIT; + return AS2 (sal%L0,%2,%k0); + } return AS2 (sal%W0,%2,%0); }") |