On Tue, Sep 23, 2008 at 1:34 AM, Daniel Berlin <[EMAIL PROTECTED]> wrote: > On Mon, Sep 22, 2008 at 8:48 AM, Mark Mitchell <[EMAIL PROTECTED]> wrote: >> Richard Guenther wrote: >> >>> char and signed char (if char is signed) are the same types for the >>> middle-end (but not for the Frontend). >> >> Is that desirable? Type-based alias analysis should be able to take >> advantage of the difference between them; a "char **" and a "signed char >> **" cannot point at the same thing, for example. >> > > Should, but currently can't. > They will both have alias set 0, last time I checked (about 2 months ago). > I imagine if we started actually enforcing strict aliasing between > signed char * and char * we'd break even more code and have even more > complaints. > It's also going to be rare that this is a useful aliasing relationship > to disambiguate between.
Also note that even if char and signed char are the same to the middle-end (you can convert between them without a conversion) pointers to them need not be the same if they have different alias sets. But I agree with Danny here. Richard.