1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-19 19:12:56 +02:00

[X86] Remove duplicate call to getValueType. NFCI.

llvm-svn: 294640
This commit is contained in:
Simon Pilgrim 2017-02-09 22:35:59 +00:00
parent f9c01c0dcd
commit 7f801d540d

View File

@ -28791,12 +28791,13 @@ static SDValue combineExtractVectorElt(SDNode *N, SelectionDAG &DAG,
if (SDValue NewOp = XFormVExtractWithShuffleIntoLoad(N, DAG, DCI))
return NewOp;
EVT VT = N->getValueType(0);
SDValue InputVector = N->getOperand(0);
SDLoc dl(InputVector);
// Detect mmx to i32 conversion through a v2i32 elt extract.
if (InputVector.getOpcode() == ISD::BITCAST && InputVector.hasOneUse() &&
N->getValueType(0) == MVT::i32 &&
InputVector.getValueType() == MVT::v2i32 &&
VT == MVT::i32 && InputVector.getValueType() == MVT::v2i32 &&
isa<ConstantSDNode>(N->getOperand(1)) &&
N->getConstantOperandVal(1) == 0) {
SDValue MMXSrc = InputVector.getOperand(0);
@ -28806,8 +28807,6 @@ static SDValue combineExtractVectorElt(SDNode *N, SelectionDAG &DAG,
return DAG.getNode(X86ISD::MMX_MOVD2W, dl, MVT::i32, MMXSrc);
}
EVT VT = N->getValueType(0);
if (VT == MVT::i1 && isa<ConstantSDNode>(N->getOperand(1)) &&
InputVector.getOpcode() == ISD::BITCAST &&
isa<ConstantSDNode>(InputVector.getOperand(0))) {