This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Major alias pessimization
- To: gcc at gcc dot gnu dot org
- Subject: Major alias pessimization
- From: kenner at vlsi1 dot ultra dot nyu dot edu (Richard Kenner)
- Date: Wed, 17 Oct 01 17:23:41 EDT
>From store_field:
/* If the address of the structure varies, then it might be on
the stack. And, stack slots may be shared across scopes.
So, two different structures, of different types, can end up
at the same location. We will give the structures alias set
zero; here we must be careful not to give non-zero alias sets
to their fields. */
set_mem_alias_set (to_rtx,
rtx_varies_p (addr, /*for_alias=*/0)
? 0 : alias_set);
This is a *very* major pessimization since it essentially means that for
all stores into aggregates, we use set 0, which means it will conflict
with anything, which essentially disables most alias set handling.
We are supposed to make sure that we never share stack slots of objects
which don't always conflict, so this should not be necessary.
There must be a better way to fix this.
What is the test case here?