This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/17064] -falias-noargument-global doesn't eliminate dead stores/loads
- From: "pinskia at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 7 Feb 2005 19:00:06 -0000
- Subject: [Bug tree-optimization/17064] -falias-noargument-global doesn't eliminate dead stores/loads
- References: <20040817140542.17064.pbrook@gcc.gnu.org>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From pinskia at gcc dot gnu dot org 2005-02-07 19:00 -------
Another testcase this time for loads:
#include <stdlib.h>
int i;
void bar(void)
{
i = 42;
}
int foo(int * p)
{
int i = *p;
bar ();
return *p + i;/* This load is dead with -fargument-noalias-global. */
}
int main()
{
int t = 2;
int t1;
t1 = foo(&t);
if (t1 != 4)
abort();
return 0;
}
--
What |Removed |Added
----------------------------------------------------------------------------
Summary|-falias-noargument-global |-falias-noargument-global
|doesn't eliminate dead |doesn't eliminate dead
|stores |stores/loads
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17064