Matthieu Longo <matthieu.lo...@arm.com> writes: > The current name REG_CFA_TOGGLE_RA_MANGLE is not representative of what > it really is, i.e. a register to represent several states, not only a > binary one. Same for dwarf2out_frame_debug_cfa_toggle_ra_mangle. > > gcc/ChangeLog: > > * combine-stack-adj.cc > (no_unhandled_cfa): Rename. > * config/aarch64/aarch64.cc > (aarch64_expand_prologue): Rename. > (aarch64_expand_epilogue): Rename. > * dwarf2cfi.cc > (dwarf2out_frame_debug_cfa_toggle_ra_mangle): Rename this... > (dwarf2out_frame_debug_cfa_negate_ra_state): To this. > (dwarf2out_frame_debug): Rename. > * reg-notes.def (REG_CFA_NOTE): Rename REG_CFA_TOGGLE_RA_MANGLE.
OK, thanks. Richard > --- > gcc/combine-stack-adj.cc | 2 +- > gcc/config/aarch64/aarch64.cc | 4 ++-- > gcc/dwarf2cfi.cc | 8 ++++---- > gcc/reg-notes.def | 8 ++++---- > 4 files changed, 11 insertions(+), 11 deletions(-) > > diff --git a/gcc/combine-stack-adj.cc b/gcc/combine-stack-adj.cc > index 2da9bf2bc1e..367d3b66b74 100644 > --- a/gcc/combine-stack-adj.cc > +++ b/gcc/combine-stack-adj.cc > @@ -212,7 +212,7 @@ no_unhandled_cfa (rtx_insn *insn) > case REG_CFA_SET_VDRAP: > case REG_CFA_WINDOW_SAVE: > case REG_CFA_FLUSH_QUEUE: > - case REG_CFA_TOGGLE_RA_MANGLE: > + case REG_CFA_NEGATE_RA_STATE: > return false; > } > > diff --git a/gcc/config/aarch64/aarch64.cc b/gcc/config/aarch64/aarch64.cc > index e0cf382998c..0af5d85c36f 100644 > --- a/gcc/config/aarch64/aarch64.cc > +++ b/gcc/config/aarch64/aarch64.cc > @@ -9606,7 +9606,7 @@ aarch64_expand_prologue (void) > default: > gcc_unreachable (); > } > - add_reg_note (insn, REG_CFA_TOGGLE_RA_MANGLE, const0_rtx); > + add_reg_note (insn, REG_CFA_NEGATE_RA_STATE, const0_rtx); > RTX_FRAME_RELATED_P (insn) = 1; > } > > @@ -10027,7 +10027,7 @@ aarch64_expand_epilogue (rtx_call_insn *sibcall) > default: > gcc_unreachable (); > } > - add_reg_note (insn, REG_CFA_TOGGLE_RA_MANGLE, const0_rtx); > + add_reg_note (insn, REG_CFA_NEGATE_RA_STATE, const0_rtx); > RTX_FRAME_RELATED_P (insn) = 1; > } > > diff --git a/gcc/dwarf2cfi.cc b/gcc/dwarf2cfi.cc > index 1231b5bb5f0..4ad9acbd6fd 100644 > --- a/gcc/dwarf2cfi.cc > +++ b/gcc/dwarf2cfi.cc > @@ -1547,13 +1547,13 @@ dwarf2out_frame_debug_cfa_window_save (void) > cur_row->window_save = true; > } > > -/* A subroutine of dwarf2out_frame_debug, process a REG_CFA_TOGGLE_RA_MANGLE. > +/* A subroutine of dwarf2out_frame_debug, process a REG_CFA_NEGATE_RA_STATE. > Note: DW_CFA_GNU_window_save dwarf opcode is reused for toggling RA mangle > state, this is a target specific operation on AArch64 and can only be used > on other targets if they don't use the window save operation otherwise. > */ > > static void > -dwarf2out_frame_debug_cfa_toggle_ra_mangle (void) > +dwarf2out_frame_debug_cfa_negate_ra_state (void) > { > dw_cfi_ref cfi = new_cfi (); > > @@ -2341,8 +2341,8 @@ dwarf2out_frame_debug (rtx_insn *insn) > handled_one = true; > break; > > - case REG_CFA_TOGGLE_RA_MANGLE: > - dwarf2out_frame_debug_cfa_toggle_ra_mangle (); > + case REG_CFA_NEGATE_RA_STATE: > + dwarf2out_frame_debug_cfa_negate_ra_state (); > handled_one = true; > break; > > diff --git a/gcc/reg-notes.def b/gcc/reg-notes.def > index 5b878fb2a1c..ddcf16b68be 100644 > --- a/gcc/reg-notes.def > +++ b/gcc/reg-notes.def > @@ -180,10 +180,10 @@ REG_CFA_NOTE (CFA_WINDOW_SAVE) > the rest of the compiler as a CALL_INSN. */ > REG_CFA_NOTE (CFA_FLUSH_QUEUE) > > -/* Attached to insns that are RTX_FRAME_RELATED_P, toggling the mangling > status > - of return address. Currently it's only used by AArch64. The argument is > - ignored. */ > -REG_CFA_NOTE (CFA_TOGGLE_RA_MANGLE) > +/* Attached to insns that are RTX_FRAME_RELATED_P, indicating an > authentication > + of the return address. Currently it's only used by AArch64. > + The argument is ignored. */ > +REG_CFA_NOTE (CFA_NEGATE_RA_STATE) > > /* Indicates what exception region an INSN belongs in. This is used > to indicate what region to which a call may throw. REGION 0