[llvm-branch-commits] [lld] [lld][LoongArch] Relax call36/tail36: R_LARCH_CALL36 (PR #123576)

Fangrui Song via llvm-branch-commits llvm-branch-commits at lists.llvm.org
Thu Feb 13 09:15:09 PST 2025


================
@@ -830,6 +832,37 @@ static void relaxPCHi20Lo12(Ctx &ctx, const InputSection &sec, size_t i,
   remove = 4;
 }
 
+// Relax code sequence.
+// From:
+//   pcaddu18i $ra, %call36(foo)
+//   jirl $ra, $ra, 0
+// To:
+//   b/bl foo
+static void relaxCall36(Ctx &ctx, const InputSection &sec, size_t i,
+                        uint64_t loc, Relocation &r, uint32_t &remove) {
+  const uint64_t symLocal =
----------------
MaskRay wrote:

Local in symLocal is misleading.

In RISCV we name this `dest`

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


More information about the llvm-branch-commits mailing list