This is the mail archive of the gcc@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]

Re: Modes on CONST_INTs


> Date: Tue, 28 Nov 2000 00:14:33 +0100
> From: Hans-Peter Nilsson <hans-peter.nilsson@axis.com>

> I mean "we have currently" as in "we have currently because of
> the current implementation of immed_double_const and trunc_int_for_mode".
> 
> I have a feeling that that's deliberately done that way to
> distinguish signed from unsigned uses. 

Last I looked, the only reason that trunc_int_for_mode etc. were not
changed is because it broke the PA port.  I haven't been able to
find a PA machine to see why this might break it, and therefore
the patch didn't make progress.

> Not that that means the code is correct, of course.  Those
> "unsigned" numbers appears *from the beginning* (in 00.rtl) as such,
> not due to the twisty maze in combine.c -- it is actually combine
> that produce the "correct" sign-extended numbers.

This just means that the bug is in the rtl-emitting machinery.

The trees _do_ use non-sign-extended values to represent unsigned
values, but they're supposed to be sign-extended when they are
converted into RTL.

-- 
- Geoffrey Keating <geoffk@geoffk.org>

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