On 11/16/2012 01:10 AM, Jakub Jelinek wrote: > Hi! > > - PR54921 invalidate sp in cselib on fp setter insn > http://gcc.gnu.org/ml/gcc-patches/2012-10/msg02035.html > (perhaps in light of PR54402 the single_succ (ENTRY_BLOCK_PTR) > from the patch should be nuked)
> + rtx expr = find_reg_note (insn, REG_FRAME_RELATED_EXPR, NULL_RTX); > + if (expr) > + pat = XEXP (expr, 0); > + if (GET_CODE (pat) == SET > + && SET_DEST (pat) == hard_frame_pointer_rtx) > + cselib_invalidate_rtx (stack_pointer_rtx); > + else if (GET_CODE (pat) == PARALLEL) This is only one possible way that FP can be set. The others are with CFA_DEF_CFA or CFA_ADJUST_CFA. Given + && frame_pointer_needed + && RTX_FRAME_RELATED_P (insn) is there any reason to do more than && modified_in_p (hard_frame_pointer_rtx, insn) ? r~