This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: should MEM tracking be able to optimize this?
- From: kenner at vlsi1 dot ultra dot nyu dot edu (Richard Kenner)
- To: dan at cgsoftware dot com
- Cc: gcc at gcc dot gnu dot org
- Date: Sun, 18 Nov 01 07:31:18 EST
- Subject: Re: should MEM tracking be able to optimize this?
Only if we are talking about interprocedural algorithms.
Intraprocedural aliasing algorithms will never get the vast majority of
common cases.
But assuming we are talking about interprocedural algorithms, you are
right of course. aliasing algorithms generally are distinguished by how
much info they retain at a given program point, and their alias relation
representation.
No, that's way more complex than I mean. The point is that there are
times (such as this case and many other similar ones) when you can
tell statically that certain types of references to field can never
conflict (because the bit positions don't overlap). The problem is
representing this information in such a way that you can make that
statement about the references themselves.
Recall the example was:
struct foo { float a[2048], b[2048]; }
It's obvious statically that X.a[i] and Y.b[j] can never conflict for any
expressions X and Y of type struct foo. But there needs to be a way to
represent this.