[PATCH] D132012: [LoongArch] Add support for llvm.eh.dwarf.cfa

WÁNG Xuěruì via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Aug 17 04:33:10 PDT 2022


xen0n marked an inline comment as done.
xen0n added inline comments.


================
Comment at: llvm/lib/Target/LoongArch/LoongArchISelLowering.cpp:181
+  MachineFunction &MF = DAG.getMachineFunction();
+  auto Size = Subtarget.getGRLen() / 8;
+  auto FI = MF.getFrameInfo().CreateFixedObject(Size, 0, false);
----------------
SixWeining wrote:
> Seems this is only used one time. Better               
> to inline it? But I can’t find this rule in llvm coding standard.
In this particular case, if all "values used only once" were to be inlined into the use site, no local values would remain. You would be left with a giant `return` which probably won't help with readability. (And I already slightly tweaked the code compared to the RISCV version.)

So I don't feel very inclined to inline more...


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D132012



More information about the llvm-commits mailing list