[llvm] [BOLT][binary-analysis] Add initial pac-ret gadget scanner (PR #122304)

Kristof Beyls via llvm-commits llvm-commits at lists.llvm.org
Fri Jan 10 06:43:28 PST 2025


kbeyls wrote:

> A first pass through the comments/documentation. I've not had a chance to go through the code yet.

Thank you, I took all your suggestions.

> Although out of scope for this patch, I'm thinking it will be worth working on a mechanism to exclude certain functions from the analysis. For example if someone has used the branch protection attribute to explicitly exclude a function from branch-protection. An obvious starting point would be some kind of exclude list file, possibly using the same format as the sanitizers.

That's a good call! I hadn't thought about that. I'll consider adding that in a later patch.

One of the other later patches planned is to introduce support for passing from the command line which functions should be considered "no-return", to reduce false positive rate. Going with the same format as the sanitizers would probably also be a good idea for that.

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


More information about the llvm-commits mailing list