[llvm] r371771 - [SelectionDAGBuilder] Simplify loop in visitSelect back to how it was before r255558.

Craig Topper via llvm-commits llvm-commits at lists.llvm.org
Thu Sep 12 14:00:33 PDT 2019


Author: ctopper
Date: Thu Sep 12 14:00:32 2019
New Revision: 371771

URL: http://llvm.org/viewvc/llvm-project?rev=371771&view=rev
Log:
[SelectionDAGBuilder] Simplify loop in visitSelect back to how it was before r255558.

This code was changed to accomodate fp128 being softened to itself
during type legalization on x86-64. This was done in order to create
libcalls while having fp128 as a legal type. We're now doing the
libcall creation during LegalizeDAG and the type legalization changes
to enable the old behavior have been removed. So this change to
SelectionDAGBuilder is no longer needed.

Modified:
    llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp

Modified: llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp?rev=371771&r1=371770&r2=371771&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp (original)
+++ llvm/trunk/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp Thu Sep 12 14:00:32 2019
@@ -3267,8 +3267,7 @@ void SelectionDAGBuilder::visitSelect(co
 
     // We care about the legality of the operation after it has been type
     // legalized.
-    while (TLI.getTypeAction(Ctx, VT) != TargetLoweringBase::TypeLegal &&
-           VT != TLI.getTypeToTransformTo(Ctx, VT))
+    while (TLI.getTypeAction(Ctx, VT) != TargetLoweringBase::TypeLegal)
       VT = TLI.getTypeToTransformTo(Ctx, VT);
 
     // If the vselect is legal, assume we want to leave this as a vector setcc +




More information about the llvm-commits mailing list