This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Checking out PR4483 (constant overflow on PPC, problems compiling Linux kernel)


David Edelsohn wrote:

>	First, please send patches to gcc-patches.
>
Ok.

>
>
>	Second, we need to be very careful with how this patch will behave
>on a 64-bit system.  As far as GCC internally is concerned, a CONST_INT
>always is a signed value.
>
I agree about being careful, but since the dest is an SI mode register, 
does it really matter?

>
>
>	This patch probably should use trunc_int_for_mode() and
>rs6000_emit_set_long_const().  This patch does not appear to take the
>correct approach.
>
The trunc_int_for_mode() simplifies things. 
 rs6000_emit_set_long_const() seems to only be for things >32 bits.

 I also modified the code to emit a single set with the truncated integer.

The bigger question is, though, should these even be getting into the 
RTL?  Should this be handled here or is the bug in the optimizations 
someplace?

-Corey


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]