[PATCH] D41774: [GlobalISel] Refactory CallLowering handleAssignments for custom <Target>CCState

Leslie Zhai via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Jan 5 09:36:45 PST 2018


xiangzhai created this revision.
xiangzhai added reviewers: t.p.northover, asb, dsanders.
Herald added subscribers: kristof.beyls, rovka.

Hi LLVM developers,

Motivation:

As Alex suggested <http://lists.llvm.org/pipermail/llvm-dev/2018-January/120098.html> ,  I refactory `handleAssignments` in the `CallLowering`,  so it is able to override `handleAssignments` in your <Target>CallLowering to initial your <Target>CCState, for example:

  RISCVCCState CCInfo(F.getCallingConv(), F.isVarArg(), MF, ArgLocs,                  
              F.getContext() ...); // Add more custom variables to meet your Target's requirement

And it also need to override `assignArg` in your <Target>CallLowering, cast from CCState to custom <Target>CCState, then do some target-specific treatment.

Please review my patch, and give me some suggestion, thanks for your teaching!

Regards,
Leslie Zhai


Repository:
  rL LLVM

https://reviews.llvm.org/D41774

Files:
  include/llvm/CodeGen/GlobalISel/CallLowering.h
  lib/CodeGen/GlobalISel/CallLowering.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D41774.128763.patch
Type: text/x-patch
Size: 6607 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180105/1385fc3f/attachment.bin>


More information about the llvm-commits mailing list