This is the mail archive of the
mailing list for the GCC project.
Re: Bugfix to convert_to_integer
- To: Richard Kenner <kenner at vlsi1 dot ultra dot nyu dot edu>
- Subject: Re: Bugfix to convert_to_integer
- From: "Joseph S. Myers" <jsm28 at cam dot ac dot uk>
- Date: Fri, 23 Feb 2001 22:29:51 +0000 (GMT)
- cc: <gcc-patches at gcc dot gnu dot org>
On Fri, 23 Feb 2001, Richard Kenner wrote:
> It isn't safe to use an unsigned type for a computation if only one operand
> was unsigned. We might have had a case where an unsigned type was converted
> to a wider signed type and then had a negative number added in that type.
> Doing the computation as unsigned in the narrower type is wrong.
> Tested on alphaev56 and applied to main and GCC 3.0 branch.
Is this something for which a testcase could be constructed? If so, could
you install one, or state which existing testcase it is?
Joseph S. Myers