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

Thiago Jung Bauermann thiago.bauermann@linaro.org
Sun Feb 2 21:21:25 GMT 2025


Hello,

Matthieu Longo <matthieu.longo@arm.com> writes:

> diff --git a/include/dwarf2.def b/include/dwarf2.def
> index 63cb35560e7..477b2ca20c0 100644
> --- a/include/dwarf2.def
> +++ b/include/dwarf2.def
> @@ -785,6 +785,8 @@ DW_CFA (DW_CFA_hi_user, 0x3f)
>
>  /* SGI/MIPS specific.  */
>  DW_CFA (DW_CFA_MIPS_advance_loc8, 0x1d)
> +/* AArch64 extensions. */
> +DW_CFA (DW_CFA_AARCH64_negate_ra_state_with_pc, 0x2c)
>  /* GNU extensions.
>     NOTE: DW_CFA_GNU_window_save is multiplexed on Sparc and AArch64.  */
>  DW_CFA (DW_CFA_GNU_window_save, 0x2d)

Would it be possible to send this part of the patch to GCC as well?

Currently building GCC for arm-eabi using a combined source tree is
failing with:

  CC       elf-eh-frame.lo
../../combined-tree-src/bfd/elf-eh-frame.c: In function ‘skip_cfa_op’:
../../combined-tree-src/bfd/elf-eh-frame.c:362:10: error: ‘DW_CFA_AARCH64_negate_ra_state_with_pc’ undeclared (first use in this function); did you mean ‘DW_CFA_AARCH64_negate_ra_state’?
  362 |     case DW_CFA_AARCH64_negate_ra_state_with_pc:
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      |          DW_CFA_AARCH64_negate_ra_state
../../combined-tree-src/bfd/elf-eh-frame.c:362:10: note: each undeclared identifier is reported only once for each function it appears in
make[4]: *** [Makefile:1762: elf-eh-frame.lo] Error 1

When I apply the change above the build succeeds.

--
Thiago


More information about the Binutils mailing list