summaryrefslogtreecommitdiffstats
path: root/llvm
diff options
context:
space:
mode:
authorEvan Cheng <evan.cheng@apple.com>2008-03-12 02:05:05 +0000
committerEvan Cheng <evan.cheng@apple.com>2008-03-12 02:05:05 +0000
commit0903aef2ffea0fa7333abdc6d4541471504cd963 (patch)
tree76321bb694339930204ba5c5cd88c1b1d5df928c /llvm
parent48a3410e25beb5277bfaad914f40aa9b22dc89d8 (diff)
downloadbcm5719-llvm-0903aef2ffea0fa7333abdc6d4541471504cd963.tar.gz
bcm5719-llvm-0903aef2ffea0fa7333abdc6d4541471504cd963.zip
Total brain cramp.
llvm-svn: 48274
Diffstat (limited to 'llvm')
-rw-r--r--llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp b/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
index 45929713369..5a6077a3ca1 100644
--- a/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
+++ b/llvm/lib/CodeGen/SelectionDAG/DAGCombiner.cpp
@@ -1103,7 +1103,7 @@ SDOperand DAGCombiner::visitSUB(SDNode *N) {
// fold (sub x, x) -> 0
if (N0 == N1) {
- if (!AfterLegalize || !MVT::isVector(VT))
+ if (AfterLegalize && ISD::isBuildVectorAllZeros(N0.Val))
// For example, zero vectors might be normalized to a particular vector
// type to ensure they are CSE'd. Avoid issuing zero vector nodes of
// *unexpected* type after legalization.
OpenPOWER on IntegriCloud