RFC: merging MEM_ATTRS
Joern Rennecke
joern.rennecke@superh.com
Tue Feb 10 21:00:00 GMT 2004
> Generally there's little point. Generally, we know that such
> variables are accessed via offset from a frame pointer, and
> we can find that.
The variables we (SuperH) were doing this optimization originally for
were function-scope static variables.
It appears with -funit-at-a-time we can now verify for all static
variables if they have their address taken.
At any rate, the other memory reference that the variable reference
was checked against for possible aliasing was an generated from an
INDIRECT_REF, and had a zero MEM_EXPR. The alias.c using
non_addressed_function_scope_var assumes that such a variable reference /
NULL_TREE MEM_EXPR pair can't alias, but that is not safe as we
have discussed before, so we want to put something else but NULL_TREE
into MEM_EXPR when we know that an indirection is involved.
More information about the Gcc
mailing list