9#ifndef LLVM_LIB_TARGET_AARCH64_AARCH64POINTERAUTH_H
10#define LLVM_LIB_TARGET_AARCH64_AARCH64POINTERAUTH_H
16namespace AArch64PAuth {
76#define AUTH_CHECK_METHOD_CL_VALUES_COMMON \
77 clEnumValN(AArch64PAuth::AuthCheckMethod::None, "none", \
78 "Do not check authenticated address"), \
79 clEnumValN(AArch64PAuth::AuthCheckMethod::DummyLoad, "load", \
80 "Perform dummy load from authenticated address"), \
81 clEnumValN(AArch64PAuth::AuthCheckMethod::HighBitsNoTBI, \
83 "Compare bits 62 and 61 of address (TBI should be disabled)")
85#define AUTH_CHECK_METHOD_CL_VALUES_LR \
86 AUTH_CHECK_METHOD_CL_VALUES_COMMON, \
87 clEnumValN(AArch64PAuth::AuthCheckMethod::XPACHint, "xpac-hint", \
88 "Compare with the result of XPACLRI")
103 Register AuthenticatedReg, Register TmpReg,
104 bool UseIKey,
unsigned BrkImm);
MachineBasicBlock MachineBasicBlock::iterator MBBI
MachineInstrBundleIterator< MachineInstr > iterator
unsigned getCheckerSizeInBytes(AuthCheckMethod Method)
Returns the number of bytes added by checkAuthenticatedRegister.
void checkAuthenticatedRegister(MachineBasicBlock::iterator MBBI, AuthCheckMethod Method, Register AuthenticatedReg, Register TmpReg, bool UseIKey, unsigned BrkImm)
Explicitly checks that pointer authentication succeeded.
AuthCheckMethod
Variants of check performed on an authenticated pointer.
@ XPACHint
Check by comparing the authenticated value with an XPAC-ed one without using PAuth instructions not e...
@ DummyLoad
Perform a load to a temporary register.
@ HighBitsNoTBI
Check by comparing bits 62 and 61 of the authenticated address.
@ None
Do not check the value at all.
This is an optimization pass for GlobalISel generic memory operations.