This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Remove redundant tst* patterns from mips.md
- From: Richard Sandiford <rsandifo at redhat dot com>
- To: gcc-patches at gcc dot gnu dot org
- Date: Sat, 28 Feb 2004 20:36:16 +0000
- Subject: Remove redundant tst* patterns from mips.md
mips.md defines tstsi and tstdi and expands them in the same way as
compares against zero. Seems a bit silly, and the docs confirm there's
no need for it.
Bootstrapped & regression tested on mips-sgi-irix6.5. The asm output of
c-torture was identical before and after the patch. Installed on trunk.
Richard
* config/mips/mips.md (tstsi, tstdi): Delete.
Index: config/mips/mips.md
===================================================================
RCS file: /cvs/gcc/gcc/gcc/config/mips/mips.md,v
retrieving revision 1.218
diff -c -p -F^\([(a-zA-Z0-9_]\|#define\) -r1.218 mips.md
*** config/mips/mips.md 19 Feb 2004 22:49:47 -0000 1.218
--- config/mips/mips.md 26 Feb 2004 20:47:48 -0000
*************** (define_expand "cmpsi"
*** 6354,6370 ****
DONE;
})
- (define_expand "tstsi"
- [(set (cc0)
- (match_operand:SI 0 "register_operand" ""))]
- ""
- {
- branch_cmp[0] = operands[0];
- branch_cmp[1] = const0_rtx;
- branch_type = CMP_SI;
- DONE;
- })
-
(define_expand "cmpdi"
[(set (cc0)
(compare:CC (match_operand:DI 0 "register_operand" "")
--- 6354,6359 ----
*************** (define_expand "cmpdi"
*** 6373,6389 ****
{
branch_cmp[0] = operands[0];
branch_cmp[1] = operands[1];
- branch_type = CMP_DI;
- DONE;
- })
-
- (define_expand "tstdi"
- [(set (cc0)
- (match_operand:DI 0 "register_operand" ""))]
- "TARGET_64BIT"
- {
- branch_cmp[0] = operands[0];
- branch_cmp[1] = const0_rtx;
branch_type = CMP_DI;
DONE;
})
--- 6362,6367 ----