This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: Removing unnecessary ADDR_EXPRs
On May 17, 2005, at 4:46 PM, Andrew Pinski wrote:
The next problem is that the forward propagation assumes that
propagating of
ADDR_EXPR should not cause us to get rid of a way to throw which is
wrong,
though I cannot prove it without honza's patch in.
Actually it was not honza's patch which causes the missed optimization
right away.
CCP is not propagating of the second ADDR_EXPR after it became
invariant.
New testcase without inlining enabled:
struct f
{
int i;
};
int g()throw()
{
f a;
f *a1 = &a;
int *i = &a1->i;
return *i;
}
Thanks,
Andrew Pinski