Created attachment 407214 [details] input C source When compiling the files attached here with gcc-4.8.4, gcc reports internal error. How to produce: $ gcc --version gcc (Gentoo 4.8.4 p1.6, pie-0.6.1) 4.8.4 Copyright (C) 2013 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. $ gcc -O0 -S mips.c #(attached file) mips.c: In function 'engine': mips.c:137:1: internal compiler error: in assign_by_spills, at lra-assigns.c:1281 } ^ Please submit a full bug report, with preprocessed source if appropriate. See <https://bugs.gentoo.org/> for instructions. then, gcc always produces the below message. A way to avoid it: below patch works. ---- --- mips.c 2015-07-20 15:45:10.395036405 +0900 +++ mips.no.c 2015-07-20 16:05:10.831234318 +0900 @@ -37,9 +37,9 @@ int i; int rtn = 0; void *ijops[64], *rops[64]; - register uint32_t inst asm("edx"); - register uint32_t pc_exec asm("ebx") = statep->pc_exec; - register uint32_t pc asm("ecx") = statep->pc; + /* register */ uint32_t inst asm("edx"); + /* register */ uint32_t pc_exec asm("ebx") = statep->pc_exec; + /* register */ uint32_t pc asm("ecx") = statep->pc; uint32_t *r = statep->r; /* */ #define COME(name) op_##name: { uint32_t ninst = memory[pc], pc_done = pc_exec; void *nlabel = engine_decode(ijops, rops, ninst); pc_exec = pc++ ---- I met this bug when I'm trying to make gcc produce good threaded code. To make gcc replicate indirect-jump code at each tail of basic blocks, I put some inline_assembler just before indirect-jumps. These inline_assemblers pritend to access all registers. So, when inline_assemblers is done, no works expect indirect-jump is left. This method stricts gcc allocating registers very tight. I guess, it does so tight to kill gcc.
Created attachment 407216 [details] emerge --info
4.8.5: ICE 4.9.3: Works Please attach preprocessed source (-save-temps).
gcc-4.9 is stable now, so throwing away older bugs we don't plan on doing backports for