summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
diff options
context:
space:
mode:
authorNadav Rotem <nadav.rotem@intel.com>2011-09-27 10:48:29 +0000
committerNadav Rotem <nadav.rotem@intel.com>2011-09-27 10:48:29 +0000
commit1b857d2762568560635cee1f283e4f3499b580de (patch)
tree01d8015f0fe9e8d3e48bf9f29b95b980d57291e8 /llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
parent614c8e51461cedde66f9356e23cd0a23fce6f6e8 (diff)
downloadbcm5719-llvm-1b857d2762568560635cee1f283e4f3499b580de.tar.gz
bcm5719-llvm-1b857d2762568560635cee1f283e4f3499b580de.zip
Revert r140463; The patch assumes that <4 x i1> is saved to memory as 4 x i8,
while the decision is to bit-pack small values. llvm-svn: 140601
Diffstat (limited to 'llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp')
-rw-r--r--llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp11
1 files changed, 1 insertions, 10 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp b/llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
index f201227ae9f..1337ef2242b 100644
--- a/llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
+++ b/llvm/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp
@@ -1180,10 +1180,6 @@ SDValue SelectionDAGLegalize::LegalizeOp(SDValue Op) {
// bytes. For example, promote EXTLOAD:i20 -> EXTLOAD:i24.
unsigned NewWidth = SrcVT.getStoreSizeInBits();
EVT NVT = EVT::getIntegerVT(*DAG.getContext(), NewWidth);
- if (SrcVT.isVector()) {
- NVT = EVT::getVectorVT(*DAG.getContext(), NVT,
- SrcVT.getVectorNumElements());
- }
SDValue Ch;
// The extra bits are guaranteed to be zero, since we stored them that
@@ -1525,12 +1521,7 @@ SDValue SelectionDAGLegalize::LegalizeOp(SDValue Op) {
// TRUNCSTORE:i1 X -> TRUNCSTORE:i8 (and X, 1)
EVT NVT = EVT::getIntegerVT(*DAG.getContext(),
StVT.getStoreSizeInBits());
- if (StVT.isVector()) {
- NVT = EVT::getVectorVT(*DAG.getContext(), NVT,
- StVT.getVectorNumElements());
- }
-
- Tmp3 = DAG.getZeroExtendInReg(Tmp3, dl, StVT.getScalarType());
+ Tmp3 = DAG.getZeroExtendInReg(Tmp3, dl, StVT);
Result = DAG.getTruncStore(Tmp1, dl, Tmp3, Tmp2, ST->getPointerInfo(),
NVT, isVolatile, isNonTemporal, Alignment);
} else if (StWidth & (StWidth - 1)) {
OpenPOWER on IntegriCloud