This is the mail archive of the
mailing list for the GCC project.
Re: [PATCH] Fix regression for missed combine opportunity
- From: Roger Sayle <roger at eyesopen dot com>
- To: Pat Haugen <pthaugen at us dot ibm dot com>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Fri, 15 Oct 2004 17:21:24 -0600 (MDT)
- Subject: Re: [PATCH] Fix regression for missed combine opportunity
On Fri, 15 Oct 2004, Pat Haugen wrote:
> 2004-10-15 Pat Haugen <firstname.lastname@example.org>
> * simplify-rtx.c (mode_signbit_p): Externalize function...
> * rtl.h (mode_signbit_p): ... to here.
> * combine.c (simplify_shift_const): Recognize PLUS signbit as
> canonical form of XOR signbit and move to outer op.
This is OK for mainline. Please also update the ChangeLog to include
PR rtl-optimization/18002 as mentioned by Andrew Pinski.
If this bootstraps and regression tests without problems against the
gcc-3_4-branch, its also suitable for gcc 3.4.
I suspect that this patch really shows that we're also missing a number
of "(shift (logical ...))" -> "(logical (shift ...))" canonicalization
transformations in simplify-rtx.c. However, in stage 3, its easier
to make this small fix to combine, than to make the more significant
changes needed to improve simplify_binary_operation.