From 8c19a8b5d5b4dd41c3155af035f40b79de3e8ef2 Mon Sep 17 00:00:00 2001 From: Bruno Cardoso Lopes Date: Thu, 28 Jul 2011 01:26:53 +0000 Subject: [PATCH] Invert the subvector insertion to be more likely to be taken as a COPY llvm-svn: 136324 --- llvm/lib/Target/X86/X86ISelLowering.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/llvm/lib/Target/X86/X86ISelLowering.cpp b/llvm/lib/Target/X86/X86ISelLowering.cpp index e1c64ea04ef1..e969553070af 100644 --- a/llvm/lib/Target/X86/X86ISelLowering.cpp +++ b/llvm/lib/Target/X86/X86ISelLowering.cpp @@ -4809,9 +4809,9 @@ X86TargetLowering::LowerBUILD_VECTOR(SDValue Op, SelectionDAG &DAG) const { NumElems/2); // Recreate the wider vector with the lower and upper part. - SDValue Vec = Insert128BitVector(DAG.getNode(ISD::UNDEF, dl, VT), Upper, - DAG.getConstant(NumElems/2, MVT::i32), DAG, dl); - return Insert128BitVector(Vec, Lower, DAG.getConstant(0, MVT::i32), + SDValue Vec = Insert128BitVector(DAG.getNode(ISD::UNDEF, dl, VT), Lower, + DAG.getConstant(0, MVT::i32), DAG, dl); + return Insert128BitVector(Vec, Upper, DAG.getConstant(NumElems/2, MVT::i32), DAG, dl); }