[llvm] [AArch64][PAC] Combine signing with address materialization (PR #130809)
Anatoly Trosinenko via llvm-commits
llvm-commits at lists.llvm.org
Thu Apr 3 12:59:29 PDT 2025
atrosinenko wrote:
@ahmedbougacha I performed some testing of #133788 compared to this PR - it seems to eliminate mostly the same set of problems. Though, if I understand it correctly, it does not touch GlobalISel at all (though I don't know whether GlobalISel is widely used).
The code base to be built by various versions of LLVM is llvm-test-suite, it was built with the same set of compilation options (optimization level is `-O2`). The resulting binaries were scanned with a prototype of a BOLT-based analyzer implemented by @kbeyls (see #122304 for the upstreamed pac-ret scanner) extended to detect other kinds of gadgets (the logic under the detection of signing oracles is mostly the same as in #134146).
The idea is that there was detected a number of signing oracles which can be resolved by this PR together with a patch for inst-combine sent as #130807, so the LLVM versions being tested are:
1. b739a3cb651dd4af2f1a47fe1f0427fe2d9460ef (the parent commit of #133788)
2. 40e0181cfaafbddc404cb9fdf353e95bff34feaf (the #133788 itself)
3. this PR rebased to the same base commit (1)
4. the patch for inst-combine cherry-picked onto (2)
5. the patch for inst-combine cherry-picked onto (3)
For the base commit (1), 1481 signing oracles are reported (note that the same utility code is linked into many different executables, so a lot of duplicated reports are possible).
The LLVM version from #133788 (2) emits only 355 signing oracles and the version from this PR (3) only emits 349 signing oracles.
With #130807 cherry-picked on top of both, there are 6 and 0 signing oracles reported, correspondingly.
I will provide more information on these 6 remaining oracles after a bit of debugging.
https://github.com/llvm/llvm-project/pull/130809
More information about the llvm-commits
mailing list