This is the mail archive of the
mailing list for the GCC project.
Re: [PATCH] Re: Checking out PR4483 (constant overflow on PPC, problems compiling Linux kernel)
- From: Geert Bosch <bosch at gnat dot com>
- To: kenner at vlsi1 dot ultra dot nyu dot edu (Richard Kenner)
- Cc: aoliva at redhat dot com, gcc-patches at gcc dot gnu dot org
- Date: Sat, 1 Dec 2001 22:43:35 -0500
- Subject: Re: [PATCH] Re: Checking out PR4483 (constant overflow on PPC, problems compiling Linux kernel)
On Saturday, December 1, 2001, at 07:46 , Richard Kenner wrote:
> There indeed would be some things simplified by having CONST_INTs (and
> integral CONST_DOUBLEs) have modes, but there are other things that
> might get more complex and I'm not sure I agree that modes are the
> right approach, but I'm also not strongly against it.
One of the reasons against it may be that *operations* need to know the
mode of their results. In this case, we have a PLUS operation in SI
The compiler should know that information. What the mode of the operand
is does not really matter here. We have two mathematical quantities
x and y
and we want to do a certain operation on them. This operation can
conceptually be separated in a mathematically exact part (the familiar
notion of +) and a rounding/truncating step. This is similar to
As long as a constant is exact, it really doesn't make a lot of sense
to talk about its mode.