The cross build for sh64-elf on x86 hosts fails during compilation
of libiberty/ramdom.c for 32bit SHmedia with

libiberty/random.c:362: internal compiler error: in push_reload, at
reload.c:1265

The following is a reduced testcase.  It ICEs with -O1 -m5-32media
on sh64-elf.

extern int tbl[32];
int n = 32;

int
foo (int idx)
{
  return tbl[idx % n];
}

Binary search shows that it starts to fail after the patch

r112637 | bonzini | 2006-04-03 20:20:07 +0900 (Mon, 03 Apr 2006) | 25 lines


-- 
           Summary: gcc fails to build on sh64-elf targets
           Product: gcc
           Version: 4.2.0
            Status: UNCONFIRMED
          Keywords: ice-on-valid-code
          Severity: normal
          Priority: P3
         Component: target
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: kkojima at gcc dot gnu dot org
 GCC build triplet: i686-pc-linux-gnu
  GCC host triplet: i686-pc-linux-gnu
GCC target triplet: sh64-elf


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

Reply via email to