From 6b4918d145e3aae31e84e6329e5428ec17535f70 Mon Sep 17 00:00:00 2001 From: Craig Topper Date: Mon, 11 Sep 2017 16:15:39 +0000 Subject: [PATCH] [SelectionDAG] Remove a check for type being a vector type after calling getShiftAmountTy. NFCI getShiftAmountTy already returns the vector type when called for vectors. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@312924 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/CodeGen/SelectionDAG/LegalizeDAG.cpp | 2 -- 1 file changed, 2 deletions(-) diff --git a/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp b/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp index 3a55e4da1ab..ba944f60f7b 100644 --- a/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp +++ b/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp @@ -2985,8 +2985,6 @@ bool SelectionDAGLegalize::ExpandNode(SDNode *Node) { // NOTE: we could fall back on load/store here too for targets without // SRA. However, it is doubtful that any exist. EVT ShiftAmountTy = TLI.getShiftAmountTy(VT, DAG.getDataLayout()); - if (VT.isVector()) - ShiftAmountTy = VT; unsigned BitsDiff = VT.getScalarSizeInBits() - ExtraVT.getScalarSizeInBits(); SDValue ShiftCst = DAG.getConstant(BitsDiff, dl, ShiftAmountTy); -- 2.50.1