This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug target/22077] [4.0/4.1 Regression] vec_all_eq does not produce good result
- From: "roger at eyesopen dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 18 Jun 2005 23:26:03 -0000
- Subject: [Bug target/22077] [4.0/4.1 Regression] vec_all_eq does not produce good result
- References: <20050615141027.22077.pinskia@gcc.gnu.org>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From roger at eyesopen dot com 2005-06-18 23:26 -------
My apologies for not knowing this had a PR. Here's the proposed solution
that I sent to Fariborz and Dale for testing.
Index: combine.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/combine.c,v
retrieving revision 1.487
diff -c -3 -p -r1.487 combine.c
*** combine.c 15 Apr 2005 03:16:20 -0000 1.487
--- combine.c 17 Jun 2005 00:14:29 -0000
*************** simplify_set (rtx x)
*** 5272,5277 ****
--- 5272,5282 ----
SUBST (SET_SRC (x), gen_rtx_COMPARE (compare_mode, op0, op1));
src = SET_SRC (x);
}
+ else if (GET_MODE (op0) == compare_mode && op1 == const0_rtx)
+ {
+ SUBST(SET_SRC (x), op0);
+ src = SET_SRC (x);
+ }
else
{
/* Otherwise, update the COMPARE if needed. */
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=22077