[PATCH] D63551: [GlobalISel] Accept multiple vregs for lowerCall's result

Diana Picus via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Jun 19 07:01:27 PDT 2019


rovka created this revision.
rovka added reviewers: aemerson, t.p.northover, aditya_nandakumar, dsanders, arsenm, igorb, aivchenk.
Herald added subscribers: Petar.Avramovic, volkan, atanasyan, hiraditya, kristof.beyls, arichardson, tpr, javed.absar, wdng, sdardis.
Herald added a project: LLVM.

Change the interface of CallLowering::lowerCall to accept several
virtual registers for the call result, instead of just one.  This is a
follow-up to D46018 <https://reviews.llvm.org/D46018>.

CallLowering::lowerReturn was similarly refactored in D49660 <https://reviews.llvm.org/D49660> and
lowerFormalArguments in D63549 <https://reviews.llvm.org/D63549>.

      

With this change, we no longer pack the virtual registers generated for
aggregates into one big lump before delegating to the target. Therefore,
the target can decide itself whether it wants to handle them as separate
pieces or use one big register.

ARM and AArch64 have been updated to use the passed in virtual registers
directly, which means we no longer need to generate so many
merge/extract instructions.

NFCI for AMDGPU, Mips and X86.


https://reviews.llvm.org/D63551

Files:
  llvm/include/llvm/CodeGen/GlobalISel/CallLowering.h
  llvm/lib/CodeGen/GlobalISel/CallLowering.cpp
  llvm/lib/CodeGen/GlobalISel/IRTranslator.cpp
  llvm/lib/Target/AArch64/AArch64CallLowering.cpp
  llvm/lib/Target/ARM/ARMCallLowering.cpp
  llvm/lib/Target/X86/X86CallLowering.cpp
  llvm/test/CodeGen/AArch64/GlobalISel/call-translator-cse.ll
  llvm/test/CodeGen/AArch64/GlobalISel/call-translator-ios.ll
  llvm/test/CodeGen/AArch64/GlobalISel/call-translator.ll
  llvm/test/CodeGen/ARM/GlobalISel/arm-param-lowering.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D63551.205577.patch
Type: text/x-patch
Size: 18770 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190619/66122a1e/attachment.bin>


More information about the llvm-commits mailing list