https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107678
--- Comment #8 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Wilco Dijkstra <wi...@gcc.gnu.org>: https://gcc.gnu.org/g:c98cd1df22fbe0829149e346a1ba9bf1f0be8a40 commit r13-5240-gc98cd1df22fbe0829149e346a1ba9bf1f0be8a40 Author: Wilco Dijkstra <wilco.dijks...@arm.com> Date: Tue Jan 3 15:57:46 2023 +0000 libgcc: Fix uninitialized RA signing on AArch64 [PR107678] A recent change only initializes the regs.how[] during Dwarf unwinding which resulted in an uninitialized offset used in return address signing and random failures during unwinding. The fix is to encode the return address signing state in REG_UNSAVED and a new state REG_UNSAVED_ARCHEXT. libgcc/ PR target/107678 * unwind-dw2.h (REG_UNSAVED_ARCHEXT): Add new enum. * unwind-dw2.c (uw_update_context_1): Add REG_UNSAVED_ARCHEXT case. * unwind-dw2-execute_cfa.h: Use REG_UNSAVED_ARCHEXT/REG_UNSAVED to encode the return address signing state. * config/aarch64/aarch64-unwind.h (aarch64_demangle_return_addr) Check current return address signing state. (aarch64_frob_update_contex): Remove.