From: Craig Topper Date: Wed, 29 Jun 2016 03:29:06 +0000 (+0000) Subject: [CodeGen] Make ShuffleVectorSDNode::commuteMask take a MutableArrayRef instead of... X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=4cd293caf80892efc19e8fc4b9620a0d42177fb9;p=llvm [CodeGen] Make ShuffleVectorSDNode::commuteMask take a MutableArrayRef instead of SmallVectorImpl. NFC. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@274095 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/include/llvm/CodeGen/SelectionDAGNodes.h b/include/llvm/CodeGen/SelectionDAGNodes.h index d316cddef89..ef52c751163 100644 --- a/include/llvm/CodeGen/SelectionDAGNodes.h +++ b/include/llvm/CodeGen/SelectionDAGNodes.h @@ -1255,7 +1255,7 @@ public: /// Change values in a shuffle permute mask assuming /// the two vector operands have swapped position. - static void commuteMask(SmallVectorImpl &Mask) { + static void commuteMask(MutableArrayRef Mask) { unsigned NumElems = Mask.size(); for (unsigned i = 0; i != NumElems; ++i) { int idx = Mask[i]; diff --git a/lib/CodeGen/SelectionDAG/SelectionDAG.cpp b/lib/CodeGen/SelectionDAG/SelectionDAG.cpp index 3073e22b9d6..f4a4207712d 100644 --- a/lib/CodeGen/SelectionDAG/SelectionDAG.cpp +++ b/lib/CodeGen/SelectionDAG/SelectionDAG.cpp @@ -1478,7 +1478,7 @@ SDValue SelectionDAG::getCondCode(ISD::CondCode Cond) { // commuteShuffle - swaps the values of N1 and N2, and swaps all indices in // the shuffle mask M that point at N1 to point at N2, and indices that point // N2 to point at N1. -static void commuteShuffle(SDValue &N1, SDValue &N2, SmallVectorImpl &M) { +static void commuteShuffle(SDValue &N1, SDValue &N2, MutableArrayRef M) { std::swap(N1, N2); ShuffleVectorSDNode::commuteMask(M); }