This is the mail archive of the
mailing list for the GCC project.
Re: working around "QImode can alias everything" missed optimizations
- To: dje at transmeta dot com, rth at cygnus dot com
- Subject: Re: working around "QImode can alias everything" missed optimizations
- From: Mike Stump <mrs at windriver dot com>
- Date: Tue, 30 May 2000 14:57:59 -0700 (PDT)
- Cc: gcc at gcc dot gnu dot org
> From: Doug Evans <firstname.lastname@example.org>
> Date: Mon, 29 May 2000 02:06:38 -0700 (PDT)
> To: Richard Henderson <email@example.com>
> Cc: firstname.lastname@example.org
> Richard Henderson writes:
> > On Fri, May 26, 2000 at 03:43:55PM -0700, Doug Evans wrote:
> > > (I'm guessing because it can't know that buf may point to itself
> > > and QImode values are allowed to alias anything).
> > Yep.
> > > So how do I work around this?
> > You can't. :-(
> I was afraid you were going to say that.
> Any interest in fixing this [dunno how yet]? GCC produces great
> code for non-QImode values (well done!). It has to be agreed that
> QImode values shouldn't be penalized (right?). [not that I would
> change behaviour of course, but rather that some new way of
> specifying a "ya, I'm a QImode (ptr) value but, gosh darn it, I
> don't alias everything" value needs to be found. Alternatively, one
> might come up with another way, but this way seems at first glance
> like the right way to go.
The standard already has this. It is called int8_t. It is not a
character type, and the alias stuff makes an exception only for
character type (s/u/plain char). So there you have it. We just need
to fix an brokenness in the compiler that doesn't respect this fact.