This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/22555] New: array in struct disables salias subvars for other fields
- From: "rguenth at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 19 Jul 2005 08:48:10 -0000
- Subject: [Bug tree-optimization/22555] New: array in struct disables salias subvars for other fields
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
struct {
int i;
int j;
int x[2];
} a;
int foo(void)
{
a.i = 1;
a.j = 0;
a.x[0] = 5;
return a.i + a.j;
}
does not get optimized, because salias disables subvars for a
because it contains an array. I have a simple patch in testing.
--
Summary: array in struct disables salias subvars for other fields
Product: gcc
Version: 4.1.0
Status: UNCONFIRMED
Keywords: missed-optimization, alias
Severity: enhancement
Priority: P2
Component: tree-optimization
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: rguenth at gcc dot gnu dot org
CC: gcc-bugs at gcc dot gnu dot org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=22555