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



             Bug #: 55433

           Summary: [4.8 Regression] ICE on excessive reloads

    Classification: Unclassified

           Product: gcc

           Version: 4.8.0

            Status: UNCONFIRMED

          Severity: normal

          Priority: P3

         Component: target

        AssignedTo: unassig...@gcc.gnu.org

        ReportedBy: phhargr...@lbl.gov

                CC: g...@intrepid.com, ne...@intrepid.com





The 9-line stand-alone test case at the end of this report fails as show below

on MacOS (at least versions 10.6 and 10.8) on x86-64 machines when targeting

the ILP32 ABI.  It notably does NOT fail on Linux/x86-64.



This was seen in SVN r193679 (on MacOSX 10.6) and r193709 (on MacOSX 10.8).



--cut--

$ gcc -m32 -O1 -fpreprocessed -c testcase.c

testcase.c: In function 'test':

testcase.c:10:1: internal compiler error: Max. number of generated reload insns

per insn is achieved (90)



 }

 ^



testcase.c:9:1: internal compiler error: Abort trap

gcc: internal compiler error: Abort trap (program cc1)

Abort trap

--cut--



Note that while the error message is the same as bug 55247, I have confirmed

that the test case attached to that bug report has NOT regressed.  Therefore, I

believe this is a different bug (though possibly related).



Some additional data:

+  -m32 is required (no bug seen w/ -m64)

+  Linux host is fine (w/ -m32 and -m64)

+  -O1 is sufficient, but -O2 and -O3 fail in the same manner

+  removing "unsigned" from the typedef eliminates the problem

+  adding -mno-sse to the command line eliminates the problem





The testcase:



typedef unsigned long long tick_t; // NOTE: no bug if "unsigned" is removed

extern int foo(void);

extern tick_t tick(void);

double test(void) {

  struct { tick_t ticks; } st;

  st.ticks = tick();

  foo(); // NOTE: no bug if this call is removed

  return (double)st.ticks;

}

Reply via email to