[PATCH] D65497: [RISCV] Avoid generating AssertZext for LP64 ABI when lowering floating Libcall

Eli Friedman via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Aug 20 13:10:00 PDT 2019


efriedma added inline comments.


================
Comment at: include/llvm/CodeGen/TargetLowering.h:3560
     bool IsPostTypeLegalization : 1;
+    SDNode *NodeBeforeSoften = nullptr;
 
----------------
shiva0217 wrote:
> luismarques wrote:
> > This new field makes the parent struct a bit misnamed, and something about this approach of passing the node in the options smells a bit to me, but I couldn't come up with a better alternative. Also, for alignment purposes it's probably better to put the SDNode pointer before the flags.
> Agree, the parent struct becomes a bit misnamed with the new field, but I can't come up a better way, either. I'll move up the new field, thanks.
> something about this approach of passing the node in the options smells a bit to me

I agree... the problem is essentially that it's tying MakeLibCallOptions to the specific usage in legalization.  In general, the API should take an "original" return type, and a list of "original" argument types.  That said, transforming the node into that form is a little awkward, so I think it's fine to leave it, with a comment that it could be generalized if necessary.


Repository:
  rL LLVM

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

https://reviews.llvm.org/D65497





More information about the llvm-commits mailing list