[PATCH v1 3/4] aarch64 DWARF: add new CFI directive for PAuth_LR

Jan Beulich jbeulich@suse.com
Mon Nov 25 16:42:38 GMT 2024


On 25.11.2024 17:28, Matthieu Longo wrote:
> --- a/gas/dw2gencfi.c
> +++ b/gas/dw2gencfi.c
> @@ -718,6 +718,7 @@ const pseudo_typeS cfi_pseudo_table[] =
>      { "cfi_restore_state", dot_cfi, DW_CFA_restore_state },
>      { "cfi_window_save", dot_cfi, DW_CFA_GNU_window_save },
>      { "cfi_negate_ra_state", dot_cfi, DW_CFA_AARCH64_negate_ra_state },
> +    { "cfi_negate_ra_state_with_pc", dot_cfi, DW_CFA_AARCH64_negate_ra_state_with_pc },
>      { "cfi_escape", dot_cfi_escape, 0 },
>      { "cfi_signal_frame", dot_cfi, CFI_signal_frame },
>      { "cfi_personality", dot_cfi_personality, 0 },
> @@ -918,6 +919,10 @@ dot_cfi (int arg)
>        cfi_add_CFA_insn (DW_CFA_GNU_window_save);
>        break;
>  
> +    case DW_CFA_AARCH64_negate_ra_state_with_pc:
> +      cfi_add_CFA_insn (DW_CFA_AARCH64_negate_ra_state_with_pc);
> +      break;

Oh, and: Shouldn't we learn from the confusion about the two other,
aliasing directives? IOW - what if this new directive is used on other
than Aarch64? Imo that would better be refused, to avoid ending up with
a similar problem again.

Jan


More information about the Binutils mailing list