diff options
| author | Chris Lattner <sabre@nondot.org> | 2008-01-05 01:22:42 +0000 | 
|---|---|---|
| committer | Chris Lattner <sabre@nondot.org> | 2008-01-05 01:22:42 +0000 | 
| commit | e666bc272d7003e575e54aeabf09066df0a71335 (patch) | |
| tree | ec24f1f4897711ce32015472fc51b900f07ce258 /llvm/lib/Transforms | |
| parent | db026d703b1ec7ee604401e9e4e98a7e75deb4a7 (diff) | |
| download | bcm5719-llvm-e666bc272d7003e575e54aeabf09066df0a71335.tar.gz bcm5719-llvm-e666bc272d7003e575e54aeabf09066df0a71335.zip | |
remove a couple more unsafe xforms in the face of overflow.
llvm-svn: 45613
Diffstat (limited to 'llvm/lib/Transforms')
| -rw-r--r-- | llvm/lib/Transforms/Scalar/InstructionCombining.cpp | 9 | 
1 files changed, 0 insertions, 9 deletions
| diff --git a/llvm/lib/Transforms/Scalar/InstructionCombining.cpp b/llvm/lib/Transforms/Scalar/InstructionCombining.cpp index 83cacbab717..1e12c79e688 100644 --- a/llvm/lib/Transforms/Scalar/InstructionCombining.cpp +++ b/llvm/lib/Transforms/Scalar/InstructionCombining.cpp @@ -4865,10 +4865,6 @@ Instruction *InstCombiner::visitICmpInst(ICmpInst &I) {          return new ICmpInst(ICmpInst::ICMP_NE, Op0, Op1);        if (isMinValuePlusOne(CI,true))              // A <s MIN+1 -> A == MIN          return new ICmpInst(ICmpInst::ICMP_EQ, Op0, SubOne(CI)); -       -      // (icmp slt (sub A B) 1) -> (icmp sle A B) -      if (CI->isOne() && match(Op0, m_Sub(m_Value(A), m_Value(B)))) -        return new ICmpInst(ICmpInst::ICMP_SLE, A, B);        break;      case ICmpInst::ICMP_UGT: @@ -4892,11 +4888,6 @@ Instruction *InstCombiner::visitICmpInst(ICmpInst &I) {          return new ICmpInst(ICmpInst::ICMP_NE, Op0, Op1);        if (isMaxValueMinusOne(CI, true))           // A >s MAX-1 -> A == MAX          return new ICmpInst(ICmpInst::ICMP_EQ, Op0, AddOne(CI)); -       -      // (icmp sgt (sub A B) -1) -> (icmp sge A B) -      if (CI->getValue().getSExtValue() == -1 &&  -          match(Op0, m_Sub(m_Value(A), m_Value(B)))) -        return new ICmpInst(ICmpInst::ICMP_SGE, A, B);        break;      case ICmpInst::ICMP_ULE: | 

