summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms
diff options
context:
space:
mode:
authorNadav Rotem <nrotem@apple.com>2013-02-01 07:59:33 +0000
committerNadav Rotem <nrotem@apple.com>2013-02-01 07:59:33 +0000
commit4349f6963eead14e67ebb0cbe0042778be683484 (patch)
tree6d8e9af71269c186d2fa556ab12358a473dbc104 /llvm/lib/Transforms
parentb5d6f5e988bc2aad10299b609fc3f060cdd2d7b3 (diff)
downloadbcm5719-llvm-4349f6963eead14e67ebb0cbe0042778be683484.tar.gz
bcm5719-llvm-4349f6963eead14e67ebb0cbe0042778be683484.zip
Revert r174152. The shift amount may overflow and in that case this transformation is illegal.
llvm-svn: 174156
Diffstat (limited to 'llvm/lib/Transforms')
-rw-r--r--llvm/lib/Transforms/InstCombine/InstCombineShifts.cpp6
1 files changed, 0 insertions, 6 deletions
diff --git a/llvm/lib/Transforms/InstCombine/InstCombineShifts.cpp b/llvm/lib/Transforms/InstCombine/InstCombineShifts.cpp
index f9e94f225f2..8cf76e5e8a9 100644
--- a/llvm/lib/Transforms/InstCombine/InstCombineShifts.cpp
+++ b/llvm/lib/Transforms/InstCombine/InstCombineShifts.cpp
@@ -709,12 +709,6 @@ Instruction *InstCombiner::visitShl(BinaryOperator &I) {
match(I.getOperand(1), m_Constant(C2)))
return BinaryOperator::CreateShl(ConstantExpr::getShl(C1, C2), A);
- // shl (c1 , add(y , c2)) -> (shl (shl(c1, c2)), y)
- if (match(I.getOperand(0), m_Constant(C1)) &&
- match(I.getOperand(1), m_Add(m_Value(A), m_Constant(C2)))) {
- return BinaryOperator::CreateShl(ConstantExpr::getShl(C1, C2), A);
- }
-
return 0;
}
OpenPOWER on IntegriCloud