[Bug tree-optimization/21610] New: ICE in make_decl_rtl

jakub at gcc dot gnu dot org gcc-bugzilla@gcc.gnu.org
Mon May 16 18:44:00 GMT 2005


struct S { char s; };
struct T { struct S t; };

struct S *const p = &((struct T * const) (0x40000000))->t;

void
foo (void)
{
  p->s = 0;
}

ICEs at -O2 e.g. on {x86_64,i386}-linux on gcc-4_0-branch.  On HEAD it seems to
work by luck.

The problem seems to be tree sharing between p's initializer and foo's body.
The gimplifier destroys the tree, on HEAD then manages to fix it up again
by further optimizations.

-- 
           Summary: ICE in make_decl_rtl
           Product: gcc
           Version: 4.0.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: tree-optimization
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: jakub at gcc dot gnu dot org
                CC: gcc-bugs at gcc dot gnu dot org


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



More information about the Gcc-bugs mailing list