The attached patch fixes an interrupt safety problem on E500 targets; this problem was introduced by the ABI fixes that were committed several months ago. On SPE targets we would generate the following code for a function epilogue: point r11 into the stack frame restore registers restore stack pointer return and the instruction scheduler, being clever, would turn this into: point r11 into the stack frame restore a few registers restore stack pointer restore remaining registers (XXX) return Which causes problems if an interrupt happens during XXX because the OS will clobber the space from which we are restoring registers, believing it to be unused. The fix is simple. We just have to tell the scheduler that we have a blocking insn just before the restore of the stack pointer. Tested on powerpc-none-linux-gnuspe with no regressions. OK to commit? -Nathan 2007-10-03 Nathan Froyd gcc/ * config/rs6000/rs6000.c (rs6000_emit_epilogue): Emit a stack tie when compiling for SPE targets due to r11 pointing into the frame.