summaryrefslogtreecommitdiffstats
path: root/llvm
diff options
context:
space:
mode:
authorJames Molloy <james.molloy@arm.com>2015-05-15 17:41:29 +0000
committerJames Molloy <james.molloy@arm.com>2015-05-15 17:41:29 +0000
commit7307cd57c550cbf4f2b7e01317a72c7f9ad52c9e (patch)
tree13a89c67f490eb0f1a2aaa1987d457db95830e90 /llvm
parent80a96d299a3ca1dfc0cb0ae3f75668d4f8c4d169 (diff)
downloadbcm5719-llvm-7307cd57c550cbf4f2b7e01317a72c7f9ad52c9e.tar.gz
bcm5719-llvm-7307cd57c550cbf4f2b7e01317a72c7f9ad52c9e.zip
[SDAGBuilder] Make the AArch64 builder happier.
I intended this loop to only unwrap SplitVector actions, but it was more broad than that, such as unwrapping WidenVector actions, which makes operations seem legal when they're not. llvm-svn: 237457
Diffstat (limited to 'llvm')
-rw-r--r--llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp b/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
index 1915a43a002..3c5d32f1749 100644
--- a/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
+++ b/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
@@ -2278,11 +2278,11 @@ void SelectionDAGBuilder::visitSelect(const User &I) {
EVT VT = ValueVTs[0];
LLVMContext &Ctx = *DAG.getContext();
- while (DAG.getTargetLoweringInfo().getTypeToTransformTo(Ctx, VT) != VT)
- VT = DAG.getTargetLoweringInfo().getTypeToTransformTo(Ctx, VT);
+ auto &TLI = DAG.getTargetLoweringInfo();
+ while (TLI.getTypeAction(Ctx, VT) == TargetLoweringBase::TypeSplitVector)
+ VT = TLI.getTypeToTransformTo(Ctx, VT);
- if (Opc != ISD::DELETED_NODE &&
- DAG.getTargetLoweringInfo().isOperationLegalOrCustom(Opc, VT)) {
+ if (Opc != ISD::DELETED_NODE && TLI.isOperationLegalOrCustom(Opc, VT)) {
OpCode = Opc;
LHSVal = getValue(LHS);
RHSVal = getValue(RHS);
OpenPOWER on IntegriCloud