[llvm] [AArch64][PAC] Move emission of LR checks in tail calls to AsmPrinter (PR #110705)

Anatoly Trosinenko via llvm-commits llvm-commits at lists.llvm.org
Mon Nov 11 04:06:21 PST 2024


================
@@ -249,6 +249,10 @@ def tcGPR64 : RegisterClass<"AArch64", [i64], 64, (sub GPR64common, X19, X20, X2
 def tcGPRx17 : RegisterClass<"AArch64", [i64], 64, (add X17)>;
 def tcGPRx16x17 : RegisterClass<"AArch64", [i64], 64, (add X16, X17)>;
 def tcGPRnotx16 : RegisterClass<"AArch64", [i64], 64, (sub tcGPR64, X16)>;
+// LR checking code expects either x16 or x17 to be available as a scratch
+// register - for that reason restrict one of two register operands of
----------------
atrosinenko wrote:

Not sure the particular operand should be mentioned here, after all, for **correctness** it is enough to restrict **any** operand and it was decided to restrict the call target instead of AddrDisc merely based on the benchmarking the code size.

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


More information about the llvm-commits mailing list