gimplify_cond_expr creates a lot of garbage later passes need to clean up, e.g.
in the common case where gimplifying COND_EXPR with one branch GOTO_EXPR and
the other NULL, or both GOTO_EXPRs.
if (D.2106 == (struct B *) &b)
  {
    goto <D.2124>;
  }
becomes:
if (D.2106 == &b[0]) goto <D.2125> else goto <D.2126>
<D.2125>:
gimple_goto <D.2124>
gimple_goto <D.2127>
<D.2126>:
<D.2127>:
while obviously:
if (D.2106 == &b[0]) goto <D.2124> else goto <D.2125>
<D.2125>:
would be enough.


-- 
           Summary: [tuples] gimplify_cond_expr should be smarter
           Product: gcc
           Version: 4.4.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: tree-optimization
        AssignedTo: dnovillo at gcc dot gnu dot org
        ReportedBy: jakub at gcc dot gnu dot org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36389

Reply via email to