[PATCH] D67128: [X86] Move x86_64 fp128 conversion to libcalls from type legalization to DAG legalization

Craig Topper via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Sep 10 14:10:17 PDT 2019


craig.topper marked 2 inline comments as done.
craig.topper added inline comments.


================
Comment at: llvm/lib/Target/X86/X86ISelLowering.cpp:18694
 
-  if (Op.getSimpleValueType().isVector())
+  if (SrcVT.isVector())
     return lowerUINT_TO_FP_vec(Op, DAG, Subtarget);
----------------
chh wrote:
> Is the change to SrcVT at line 18694 to fix some other bug or an error?
> Before this change, it was Op.getSimpleValueType() or DstVT.
> Why is it changed to SrcVT?
> 
> 
Looks like a mistake on my part. I didn't mean to change it. If DstVT is a vector, SrcVT will also be a vector and vice versa so it doesn't matter. But I'll change it back to DstVT.


================
Comment at: llvm/lib/Target/X86/X86ISelLowering.cpp:19520
+  if (VT == MVT::f128) {
+    RTLIB::Libcall LC; LC = RTLIB::getFPEXT(SVT, VT);
+    return LowerF128Call(Op, DAG, LC);
----------------
chh wrote:
> Coding style comment.
> Shouldn't it be
>   RTLIB::Libcall LC = RTLIB::getFPEXT(SVT, VT);
> 
I copied part of this from somewhere else that had an if after the declaration. Looks like I failed to merge the two lines together the way I intended


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D67128





More information about the llvm-commits mailing list