[llvm] "[bolt][aarch64] Fixed indirect call instrumentation snippet" (PR #141918)
Paschalis Mpeis via llvm-commits
llvm-commits at lists.llvm.org
Tue Nov 4 08:27:03 PST 2025
================
@@ -2472,30 +2516,44 @@ class AArch64MCPlusBuilder : public MCPlusBuilder {
// ldr x30, [sp], #16
// b IndCallHandler
InstructionListType Insts;
+
Insts.emplace_back();
- createPushRegisters(Insts.back(), AArch64::X0, AArch64::X1);
+ createPushRegisters(Insts.back(), getIntArgRegister(0),
+ getIntArgRegister(1));
+
Insts.emplace_back();
getSystemFlag(Insts.back(), getIntArgRegister(1));
+
+ Insts.emplace_back();
+ storeReg(Insts.back(), getIntArgRegister(1), getSpRegister(/*Size*/ 8));
----------------
paschalis-mpeis wrote:
Should the 'Code sequence' at the beginning of the function be edited to accommodate this change here (between mrs and expanded adr)?
Also a nit, since you modified this function: may fix typo on line [L2506](https://github.com/llvm/llvm-project/pull/141918/files#diff-79a437ac4fd4f32fe9c0862fd8ae746d4573029d163f1b97fd7ac46c92e2c2d7R2506):
`InstrTampoline` -> `InstrTrampoline`
https://github.com/llvm/llvm-project/pull/141918
More information about the llvm-commits
mailing list