[Bug tree-optimization/53438] [4.7/4.8 Regression] Bitfield store replaced with full-byte store
rguenth at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Tue May 22 10:50:00 GMT 2012
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53438
Richard Guenther <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Last reconfirmed| |2012-05-22
Ever Confirmed|0 |1
--- Comment #5 from Richard Guenther <rguenth at gcc dot gnu.org> 2012-05-22 10:47:53 UTC ---
Confirmed. The following C testcase works correctly:
struct S { _Bool b : 1; char c : 7; };
void bar (struct S s)
{
if (s.c != 7)
abort ();
}
int foo (_Bool b)
{
struct S s;
s.c = 7;
s.b = b;
bar (s);
return s.c;
}
but for some reason your reduced testcase ends up producing a MEM_REF
instead of a component-ref to store b instead.
More information about the Gcc-bugs
mailing list