http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50063
--- Comment #17 from Jakub Jelinek <jakub at gcc dot gnu.org> 2011-12-20 06:54:00 UTC --- FIND_BASE_TERM is actually supposed just an alternate rtx expression, not its find_base_term value, so something like (perhaps with more conditions, when r28 is never equal to r32 in the body or r32 isn't initialized from r28, it doesn't need to be done): if (reload_completed && frame_pointer_needed && REG_P (x) && REGNO (x) == STACK_POINTER_REGNUM) return frame_pointer_rtx; return NULL_RTX;