[PATCH] D137821: [LoongArch] Handle register spill in BranchRelaxation pass

Lu Weining via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Nov 13 22:29:05 PST 2022


SixWeining accepted this revision.
SixWeining added a comment.
This revision is now accepted and ready to land.

LGTM. But it's better to be reviewed by @wangleiat because I know he is also planning to add an another spill slot.



================
Comment at: llvm/lib/Target/LoongArch/LoongArchFrameLowering.cpp:139
 
+  // Far branches over 27-bit offset require a spill slot for scratch register.
+  if (!isInt<27>(estimateFunctionSizeInBytes(TII, MF))) {
----------------
beyond?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D137821/new/

https://reviews.llvm.org/D137821



More information about the llvm-commits mailing list