diff options
author | Ahmed Bougacha <ahmed@bougacha.org> | 2024-06-26 18:54:40 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-06-26 18:54:40 -0700 |
commit | 34e5a71b3219391309eb498a55e4d49831e1f9ab (patch) | |
tree | 260baa34d53e346fc5d127a9a42ce193b2a33f5e /llvm/lib/CodeGen/MachineBasicBlock.cpp | |
parent | 1b8ab2f08998d3220e5d95003d47bb3d7cac966b (diff) | |
download | llvm-34e5a71b3219391309eb498a55e4d49831e1f9ab.zip llvm-34e5a71b3219391309eb498a55e4d49831e1f9ab.tar.gz llvm-34e5a71b3219391309eb498a55e4d49831e1f9ab.tar.bz2 |
[InstCombine] Combine ptrauth constants into ptrauth intrinsics. (#94705)
When we encounter two consecutive ptrauth intrinsics, we can already
combine the inner matching sign + auth pair, e.g.:
resign(sign(p,ks,ds),ks,ds,kr,dr) -> sign(p,kr,dr)
We can generalize that to ptrauth constants, which are effectively
constant equivalents to ptrauth.sign, i.e.:
resign(ptrauth(p,ks,ds),ks,ds,kr,dr) -> ptrauth(p,kr,dr)
auth(ptrauth(p,k,d),k,d) -> p
While there, cleanup a redundant return after eraseInstFromFunction in
the shared (intrinsic|constant)->intrinsic folding code.
Diffstat (limited to 'llvm/lib/CodeGen/MachineBasicBlock.cpp')
0 files changed, 0 insertions, 0 deletions