summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
diff options
context:
space:
mode:
authorNate Begeman <natebegeman@mac.com>2005-11-22 18:16:00 +0000
committerNate Begeman <natebegeman@mac.com>2005-11-22 18:16:00 +0000
commitd37c13154ae0e790cb7313a4465c5f9b9a3c49a2 (patch)
tree6e1017531ca6dd2e1efb0defe93246c68da3bc7f /llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
parent0294e33ea4b4af290232ecd1d65012e80e130950 (diff)
downloadbcm5719-llvm-d37c13154ae0e790cb7313a4465c5f9b9a3c49a2.tar.gz
bcm5719-llvm-d37c13154ae0e790cb7313a4465c5f9b9a3c49a2.zip
Check in code to scalarize arbitrarily wide packed types for some simple
vector operations (load, add, sub, mul). This allows us to codegen: void %foo(<4 x float> * %a) { entry: %tmp1 = load <4 x float> * %a; %tmp2 = add <4 x float> %tmp1, %tmp1 store <4 x float> %tmp2, <4 x float> *%a ret void } on ppc as: _foo: lfs f0, 12(r3) lfs f1, 8(r3) lfs f2, 4(r3) lfs f3, 0(r3) fadds f0, f0, f0 fadds f1, f1, f1 fadds f2, f2, f2 fadds f3, f3, f3 stfs f0, 12(r3) stfs f1, 8(r3) stfs f2, 4(r3) stfs f3, 0(r3) blr llvm-svn: 24484
Diffstat (limited to 'llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp')
-rw-r--r--llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp b/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
index 685bdabd49f..7676ead3551 100644
--- a/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
+++ b/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
@@ -1106,7 +1106,7 @@ SDOperand SelectionDAG::getVecLoad(unsigned Count, MVT::ValueType EVT,
Ops.push_back(SV);
std::vector<MVT::ValueType> VTs;
VTs.reserve(2);
- VTs.push_back(EVT); VTs.push_back(MVT::Other); // Add token chain.
+ VTs.push_back(MVT::Vector); VTs.push_back(MVT::Other); // Add token chain.
return getNode(ISD::VLOAD, VTs, Ops);
}
OpenPOWER on IntegriCloud