[llvm-commits] CVS: llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp
Chris Lattner
lattner at cs.uiuc.edu
Thu Mar 30 18:12:30 PST 2006
Changes in directory llvm/lib/CodeGen/SelectionDAG:
SelectionDAGISel.cpp updated: 1.213 -> 1.214
---
Log message:
Make sure to pass enough values to phi nodes when we are dealing with
decimated vectors. This fixes UnitTests/Vector/sumarray-dbl.c
---
Diffs of the changes: (+10 -2)
SelectionDAGISel.cpp | 12 ++++++++++--
1 files changed, 10 insertions(+), 2 deletions(-)
Index: llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp
diff -u llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp:1.213 llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp:1.214
--- llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp:1.213 Thu Mar 30 20:06:56 2006
+++ llvm/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp Thu Mar 30 20:12:18 2006
@@ -2805,8 +2805,16 @@
// Remember that this register needs to added to the machine PHI node as
// the input for this MBB.
- unsigned NumElements =
- TLI.getNumElements(TLI.getValueType(PN->getType()));
+ MVT::ValueType VT = TLI.getValueType(PN->getType());
+ unsigned NumElements;
+ if (VT != MVT::Vector)
+ NumElements = TLI.getNumElements(VT);
+ else {
+ MVT::ValueType VT1,VT2;
+ NumElements =
+ TLI.getPackedTypeBreakdown(cast<PackedType>(PN->getType()),
+ VT1, VT2);
+ }
for (unsigned i = 0, e = NumElements; i != e; ++i)
PHINodesToUpdate.push_back(std::make_pair(MBBI++, Reg+i));
}
More information about the llvm-commits
mailing list