On 02/06/2014 01:55 AM, Richard Sandiford wrote: > OK, I agree that's not 4.9 material. What about the other change > of replacing: > > REF_CFA_DEF_CFA (plus (stack_pointer_rtx) (const_int 160/96)) > > with: > > REF_CFA_ADJUST_CFA (set (stack_pointer_rtx) > (plus (current_cfa_base) (const_int offset))) > > ? That works on its own, but having both a REG_CFA_ADJUST_CFA that assigns > to stack_pointer_rtx and a REG_CFA_RESTORE for stack_pointer_rtx feels like > a double assignment.
It does seem like it. I suppose it would be easy to suppress the RESTORE of the stack pointer, without changing the save at all. > Personally I'd prefer to leave the REG_CFA_DEF_CFA > as-is for now and change all three (the save, the restore and the CFA > definition) at the same time. Yeah, well... > * var-tracking.c (insn_stack_adjust_offset_pre_post): Handle > REG_CFA_ADJUST_CFA. > * config/s390/s390.c (s390_add_restore_cfa_note): New function. > (s390_emit_epilogue): Use it. Looks fine to me, as far as it goes. r~