On May 7, 2012, at 15:57 , Olivier Hainque wrote: > My first attempt at building there failed, with > > --target=powerpc-eabispe --with-cpu=8548 --enable-languages=c > --disable-libada > > (internal compiler error on unwind-dw2.c) This failure reproduces with > an unpatched tree as well, so there's something already broken in this area.
This appears to be a fallout of the (very nice !) prologue/epilogue cleanup series issued last april, in particular rev 186797 corresponding to http://gcc.gnu.org/ml/gcc-patches/2012-04/msg01014.html (Alan cc'ed) This piece: (emit_frame_save): Don't handle reg+reg addressing. introduces an assert on which we now trip compiling unwind-dw2.c for SPE configurations. We now fall into the TARGET_SPE_ABI part of /* Some cases that need register indexed addressing. */ gcc_checking_assert (!((TARGET_ALTIVEC_ABI && ALTIVEC_VECTOR_MODE (mode)) || (TARGET_VSX && ALTIVEC_OR_VSX_VECTOR_MODE (mode)) || (TARGET_E500_DOUBLE && mode == DFmode) || (TARGET_SPE_ABI && SPE_VECTOR_MODE (mode) && !SPE_CONST_OFFSET_OK (offset)))); in emit_frame_save while compiling uw_install_context. The call comes from this part of rs6000_emit_prologue: /* ??? There's no need to emit actual instructions here, but it's the easiest way to get the frame unwind information emitted. */ if (crtl->calls_eh_return) { unsigned int i, regno; for (i = 0; ; ++i) { regno = EH_RETURN_DATA_REGNO (i); if (regno == INVALID_REGNUM) break; emit_frame_save (frame_reg_rtx, reg_mode, regno, info->ehrd_offset + frame_off + reg_size * (int) i, sp_off - frame_off); } } The crash reproduces on this artificial reproducer: void install (long offset, void * handler) { volatile int x [4096]; __builtin_eh_return (offset, handler); } configure --enable-languages=c --disable-libada --target=powerpc-eabispe make ... ./cc1 ice.c ... ice.c: In function "install": ice.c:6:1: internal compiler error: in emit_frame_save, at config/rs6000/rs6000.c:18979