This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/58570] [4.9 Regression] wrong code for bitfields at -O2 and above
- From: "ebotcazou at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Mon, 07 Oct 2013 21:13:28 +0000
- Subject: [Bug tree-optimization/58570] [4.9 Regression] wrong code for bitfields at -O2 and above
- Auto-submitted: auto-generated
- References: <bug-58570-4 at http dot gcc dot gnu dot org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58570
Eric Botcazou <ebotcazou at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC|bernd.edlinger at hotmail dot de |
Assignee|unassigned at gcc dot gnu.org |ebotcazou at gcc dot gnu.org
Summary|[4.9 Regression] wrong code |[4.9 Regression] wrong code
|at -Os and above on |for bitfields at -O2 and
|x86_64-linux-gnu (both |above
|32-bit and 64-bit modes) |
--- Comment #5 from Eric Botcazou <ebotcazou at gcc dot gnu.org> ---
I think we just want to copy the following from
nonoverlapping_component_refs_p:
/* If we're left with accessing different fields of a structure, then no
possible overlap, unless they are both bitfields. */
if (TREE_CODE (typex) == RECORD_TYPE && fieldx != fieldy)
return !(DECL_BIT_FIELD (fieldx) && DECL_BIT_FIELD (fieldy));
over to nonoverlapping_component_refs_of_decl_p.