diff options
author | Chris Lattner <sabre@nondot.org> | 2006-03-22 01:46:54 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2006-03-22 01:46:54 +0000 |
commit | 8fa445a89d39c3dd4b03dd64c77aab296303f156 (patch) | |
tree | d446a9c3e46a91ea6f241448437cfeec24a43c09 /llvm/lib/CodeGen | |
parent | 4e7371758fedc08d931b837ff808c9c2e6b3822c (diff) | |
download | bcm5719-llvm-8fa445a89d39c3dd4b03dd64c77aab296303f156.tar.gz bcm5719-llvm-8fa445a89d39c3dd4b03dd64c77aab296303f156.zip |
Endianness does not affect the order of vector fields. This fixes
SingleSource/UnitTests/Vector/build.c
llvm-svn: 26936
Diffstat (limited to 'llvm/lib/CodeGen')
-rw-r--r-- | llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp b/llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp index 5a1aef7a7d4..1a951bb7044 100644 --- a/llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp +++ b/llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp @@ -3155,7 +3155,6 @@ SDOperand SelectionDAGLegalize::ExpandBUILD_VECTOR(SDNode *Node) { // Emit a store of each element to the stack slot. std::vector<SDOperand> Stores; - bool isLittleEndian = TLI.isLittleEndian(); unsigned TypeByteSize = MVT::getSizeInBits(Node->getOperand(0).getValueType())/8; unsigned VectorSize = MVT::getSizeInBits(VT)/8; @@ -3164,11 +3163,7 @@ SDOperand SelectionDAGLegalize::ExpandBUILD_VECTOR(SDNode *Node) { // Ignore undef elements. if (Node->getOperand(i).getOpcode() == ISD::UNDEF) continue; - unsigned Offset; - if (isLittleEndian) - Offset = TypeByteSize*i; - else - Offset = TypeByteSize*(e-i-1); + unsigned Offset = TypeByteSize*i; SDOperand Idx = DAG.getConstant(Offset, FIPtr.getValueType()); Idx = DAG.getNode(ISD::ADD, FIPtr.getValueType(), FIPtr, Idx); |