[clang] [llvm] [Clang][ARM][AArch64] Alway emit protection attributes for functions. (PR #82819)

Eli Friedman via cfe-commits cfe-commits at lists.llvm.org
Tue Jun 25 11:35:17 PDT 2024


efriedma-quic wrote:

Hmm... so basically, the program is partitioned into parts with branch enforcement disabled, and parts with branch enforcement enabled, and there's some defined transition between the two?  So in this case, the metadata is nonsense, and you want to ignore it.  I guess that makes sense.

This means missed optimizations for the case where the program can't mess with the BTI-enabled state, though: if you build a library with BTI enabled and link it into a program with BTI disabled, LTO becomes severely restricted.  I guess that might be rare enough it doesn't matter.

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


More information about the cfe-commits mailing list