aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorNadav Rotem <nadav.rotem@intel.com>2011-09-21 14:34:38 +0000
committerNadav Rotem <nadav.rotem@intel.com>2011-09-21 14:34:38 +0000
commit1147248e6f40f2e5655f3d8243fe7ba49ed75d0a (patch)
tree896693bf7a80594d9e6370fdc27a7debb389ba7f /lib
parent9c6cdf4c1c82842a97e02bef4cef2431ad2e61a3 (diff)
[VECTOR-SELECT] Address one of the bugs in pr10902.
Vector SetCC result types need to be type-legalized. This code worked before because scalar result types are known to be legal. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@140249 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r--lib/CodeGen/SelectionDAG/LegalizeIntegerTypes.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/CodeGen/SelectionDAG/LegalizeIntegerTypes.cpp b/lib/CodeGen/SelectionDAG/LegalizeIntegerTypes.cpp
index 27b87e9277..a3c926c3fa 100644
--- a/lib/CodeGen/SelectionDAG/LegalizeIntegerTypes.cpp
+++ b/lib/CodeGen/SelectionDAG/LegalizeIntegerTypes.cpp
@@ -500,6 +500,8 @@ SDValue DAGTypeLegalizer::PromoteIntRes_SELECT_CC(SDNode *N) {
SDValue DAGTypeLegalizer::PromoteIntRes_SETCC(SDNode *N) {
EVT SVT = TLI.getSetCCResultType(N->getOperand(0).getValueType());
+ // Vector setcc result types need to be leglized.
+ SVT = TLI.getTypeToTransformTo(*DAG.getContext(), SVT);
DebugLoc dl = N->getDebugLoc();
assert(SVT.isVector() == N->getOperand(0).getValueType().isVector() &&