[clang] [PAC][clang] Handle pauthtest environment and ABI in Linux-specific code (PR #113151)

Daniil Kovalev via cfe-commits cfe-commits at lists.llvm.org
Tue Sep 16 01:26:49 PDT 2025


kovdan01 wrote:

> > ELF PAuth is an object file format specific feature that isn't coupled with a specific OS. Keeping it in generic code might help other OSes (e.g. *BSD), if they ever adopt PAuth.
> 
> In fact, it is coupled. The idea here is that PAuth effectively defines another platform ABI (or several as on Darwin outside arm64e). The platform might chose different signing schemes, default options, and object marking scheme. Even more, the platform might chose not to expose `-fptrauth-*` options at all (as they do change ABI and their use by end users might be discouraged), so it does make sense to move the handling to target-specific code.
> 
> Finally, `pauthtest` environment is intended for testing / experiments, not for end users. Likely the platform would chose different environment (e.g. `pauth`).

@MaskRay Could you please take a look at this PR considering the latest comment from @asl?

https://github.com/llvm/llvm-project/pull/113151


More information about the cfe-commits mailing list