This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [tree-ssa] must-alias analysis
- From: Jason Merrill <jason at redhat dot com>
- To: law at redhat dot com
- Cc: Diego Novillo <dnovillo at redhat dot com>, "gcc-patches at gcc dot gnu dot org" <gcc-patches at gcc dot gnu dot org>
- Date: Mon, 14 Jul 2003 14:20:30 -0400
- Subject: Re: [tree-ssa] must-alias analysis
- References: <200307141804.h6EI4PXX024750@speedy.slc.redhat.com>
On Mon, 14 Jul 2003 12:04:25 -0600, law@redhat.com wrote:
> >We currently do not propagate ADDR_EXPR values that have been type
> >casted. So, things like 'PTR = (type *)&VAR' are not propagated. The
> >problem with this is that we would need to fold instances of *PTR into
> >(type)VAR, which would produce non-GIMPLE code and confuse the
> >optimizers. I'm not quite sure how to handle this one. I think it's
> >important because right now we are not handling code like this (from Joe
> >Buck's sample code a while back):
> We've *REALLY* got to fix our handling of NOP_EXPRs. REALLY REALLY REALLY.
>
> They're getting in the way far too often. I really want to see someone
> tackle that problem. I'm consistently running into cases where we either
> miss a redundancy, generate a useless copy, etc because of the way we
> handle NOP_EXPRs.
Yep. As Nathanael was pointing out, most of the NOPs are, in fact, nops,
changing between pointer and reference or adjusting cv-quals. In most
cases we should be able to remove them and just change the type of the
expression they wrap. I'll work on such a change.
Jason