------- Comment #22 from jakub at gcc dot gnu dot org 2008-08-11 16:25 ------- Created an attachment (id=16053) --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=16053&action=view) pop.patch
Additional patch on top of sp=reg.patch patch, which should fix the SH4 case - the simplistic stack_adjust_offset wouldn't see the adjustments in pop instructions, only push instructions. I'm not sure if it is enough to do it this way, or whether for_each_rtx shouldn't be called instead to find all embedded MEMs with {PRE,POST}_{INC,DEC,MODIFY} operands on sp register. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36998