This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
RE: Problem regarding canonicalization
- From: "Dave Korn" <dave dot korn at artimi dot com>
- To: "'Ashwin'" <ashwin at codito dot com>, "'GCC mailing list'" <gcc at gcc dot gnu dot org>
- Date: Tue, 4 Apr 2006 11:13:26 +0100
- Subject: RE: Problem regarding canonicalization
On 04 April 2006 10:39, Ashwin wrote:
> I have a combiner pattern that converts a sub-cmp pattern to a cmp insn,
> something like this -
> "if (a-1 < 0)"
> is converted to
> "if (a<1)"
>
> When 1 is subtracted from MIN,
> Similar problem seems to arise when MAX is passed to a function that
> does "return (++a < 0).
>
> How do I tackle this problem? Anything I may be missing?
Integer under/overflow being undefined behaviour? I imagine the point of
this testcase is to spot potential breakage introduced by just such
optimisations?
cheers,
DaveK
--
Can't think of a witty .sigline today....