# LLVM Pointer Authentication sync-ups

**URL:** <https://discourse.llvm.org/t/llvm-pointer-authentication-sync-ups/62661>\
**Category:** LLVM Project\
**Created:** [May 20, 2022, 11:47am UTC](https://discourse.llvm.org/t/llvm-pointer-authentication-sync-ups/62661 "2022-05-20T11:47:06Z")\
**Posts on this page:** 1\
**Showing post:** 23

<div class="post-metadata">

**Author:** ![akorobeynikov](https://sea1.discourse-cdn.com/flex021/user_avatar/discourse.llvm.org/akorobeynikov/32/17_2.png) [@akorobeynikov](https://discourse.llvm.org/u/akorobeynikov)\
**Post date:** [November 20, 2023, 11:14pm UTC](https://discourse.llvm.org/t/llvm-pointer-authentication-sync-ups/62661/23 "2023-11-20T23:14:06Z")

</div>

Dear All,

We are happy to provide the very first proof-of-concept [branch](https://github.com/access-softek/llvm-project/commits/elf-pauth) of LLVM+clang+runtime libraries that includes pointer authentication support for ELF targets.

Everything is based on top of downstream branch by @ahmedbougacha with ELF support patches on top as well as some bug fixes.

There is also a patch for MUSL that adds support for pauth ELF relocations: [[AArch64] Add initial support for PAC relocs by eleviant · Pull Request #1 · access-softek/musl · GitHub](https://github.com/access-softek/musl/pull/1)

We verified that LLVM testsuite compiled with pauth successfully passes on pauth-enabled AArch64 board.

Notes and known issues:

- There is some code generation instability (different, albeit correct, code is generation on Linux and Mac hosts)
- Complete LLDB support is currently WIP. For now stack tracing, etc. only works until the first signed pointers
- Some things are not yet decided / implemented (e.g. emission of `.note` sections, when / how one would check them inside dynamic loader, etc.).
- Relocation numbers are used from the still unmerged AArch64 ELF ABI pull request: [[AAELF64][PAUTHABI64] Assign PAuthABI relocation codes. by smithp35 · Pull Request #227 · ARM-software/abi-aa · GitHub](https://github.com/ARM-software/abi-aa/pull/227)

Eventually all patches will be a part of LLVM mainline, however, there are some roadblocks that need to be broken. Please let us know if there are any issues, etc. with the code provided.

---

_[View the full topic](https://discourse.llvm.org/t/llvm-pointer-authentication-sync-ups/62661)._
