This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [patch] for PR18942
- From: Roger Sayle <roger at eyesopen dot com>
- To: Zdenek Dvorak <rakdver at atrey dot karlin dot mff dot cuni dot cz>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Sun, 19 Dec 2004 10:32:32 -0700 (MST)
- Subject: Re: [patch] for PR18942
On Sun, 19 Dec 2004, Zdenek Dvorak wrote:
> > Then finally this transformation can also be generalized to handle the
> > MINUS case as well, i.e. "(x - C1) == C2" -> "x == (C2 + C1)".
>
> I thought we canonicalize (minus x cst) to (plus x (-cst))? Although I
> cannot find it anywhere just now.
We do this canonicalization for CONST_INT and CONST_DOUBLE, I'm just
not sure that we also do it for other forms of constants such as CONST,
SYMBOL_REF, LABEL_REF, etc...
Roger
--