llvm-6502/lib/Transforms/InstCombine
Chris Lattner 6cdf2ea98e implement the first part of PR8882: when lowering an inbounds
gep to explicit addressing, we know that none of the intermediate
computation overflows.

This could use review: it seems that the shifts certainly wouldn't
overflow, but could the intermediate adds overflow if there is a 
negative index?

Previously the testcase would instcombine to:

define i1 @test(i64 %i) {
  %p1.idx.mask = and i64 %i, 4611686018427387903
  %cmp = icmp eq i64 %p1.idx.mask, 1000
  ret i1 %cmp
}

now we get:

define i1 @test(i64 %i) {
  %cmp = icmp eq i64 %i, 1000
  ret i1 %cmp
}



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@125271 91177308-0d34-0410-b5e6-96231b3b80d8
2011-02-10 07:11:16 +00:00
..
CMakeLists.txt Removed a bunch of unnecessary target_link_libraries. 2010-09-28 22:39:14 +00:00
InstCombine.h Call SimplifyFDivInst() in InstCombiner::visitFDiv(). 2011-01-29 17:50:27 +00:00
InstCombineAddSub.cpp implement the first part of PR8882: when lowering an inbounds 2011-02-10 07:11:16 +00:00
InstCombineAndOrXor.cpp more cleanups, notably bitcast isn't used for "signed to unsigned type 2011-02-10 05:17:27 +00:00
InstCombineCalls.cpp Teach instcombine about the rest of the SSE and SSE2 conversion 2011-01-10 07:19:37 +00:00
InstCombineCasts.cpp implement an instcombine xform that canonicalizes casts outside of and-with-constant operations. 2011-01-15 06:32:33 +00:00
InstCombineCompares.cpp Enhance the "compare with shift" and "compare with div" 2011-02-10 05:23:05 +00:00
InstCombineLoadStoreAlloca.cpp Move getOrEnforceKnownAlignment out of instcombine into Transforms/Utils. 2010-12-25 20:37:57 +00:00
InstCombineMulDivRem.cpp Enhance a bunch of transformations in instcombine to start generating 2011-02-10 05:36:31 +00:00
InstCombinePHI.cpp Teach InstructionSimplify about phi nodes. I chose to have it simply 2010-11-14 13:30:18 +00:00
InstCombineSelect.cpp Fold select + select where both selects are on the same condition. 2011-01-28 03:28:10 +00:00
InstCombineShifts.cpp Enhance a bunch of transformations in instcombine to start generating 2011-02-10 05:36:31 +00:00
InstCombineSimplifyDemanded.cpp teach SimplifyDemandedBits that exact shifts demand the bits they 2011-02-10 05:09:34 +00:00
InstCombineVectorOps.cpp PR5207: Rename overloaded APInt methods set(), clear(), flip() to 2010-12-01 08:53:58 +00:00
InstCombineWorklist.h I got tired of VISIBILITY_HIDDEN colliding with the gcc enum. Rename it 2010-05-11 20:16:09 +00:00
InstructionCombining.cpp Conservatively, clear optional flags, such as nsw, when performing 2011-02-02 02:05:46 +00:00
Makefile make -fno-rtti the default unless a directory builds with REQUIRES_RTTI. 2010-01-24 20:43:08 +00:00