I'm not familiar with gcc internals enough to fix this the right way, this is a big hammer fix to avoid exposing mangled pointer representation to user code when pointer signing is used on aarch64. I.e. this is not an optimal fix just to show how i would want the ABI to work.
This touches unwinder ABI, unwinder debugger hook ABI (patch 3/4), __builtin_return_address (1/4), __builtin_eh_return (2/4) usage and updates the documentation a bit in this area (4/4). Tests are still running. (I expect some existing target tests will need to be updated.) The last patch is same as I sent before (just with changelog this time). Szabolcs Nagy (4): aarch64: fix return address access with pac [PR94891][PR94791] aarch64: fix __builtin_eh_return with pac-ret [PR94891] libgcc: fix the handling of return address mangling [PR94891] doc: Clarify __builtin_return_address [PR94891] gcc/config/aarch64/aarch64-protos.h | 1 + gcc/config/aarch64/aarch64.c | 24 +++++++++++++++++- gcc/config/aarch64/aarch64.h | 2 +- gcc/doc/extend.texi | 16 ++++++++++-- libgcc/config/aarch64/aarch64-unwind.h | 34 ++++---------------------- libgcc/unwind-dw2.c | 34 ++++++-------------------- 6 files changed, 52 insertions(+), 59 deletions(-) -- 2.17.1