- Nov 27, 2011
-
-
Benjamin Kramer authored
llvm-svn: 145154
-
- Nov 02, 2011
-
-
Andrew Trick authored
We've been hitting asserts in this code due to the many supported combintions of modes (iv-rewrite/no-iv-rewrite) and IV types. This second rewrite of the code attempts to deal with these cases systematically. llvm-svn: 143546
-
Chandler Carruth authored
silence -Wparentheses. llvm-svn: 143534
-
Andrew Trick authored
Narrowest possible fix for PR11279. llvm-svn: 143522
-
- Oct 28, 2011
-
-
Andrew Trick authored
Fixes rdar://10359193 Indvar LinearFunctionTestReplace assertion llvm-svn: 143183
-
- Oct 27, 2011
-
-
Eli Friedman authored
It is not safe to sink an alloca into a stacksave/stackrestore pair, so don't do that. <rdar://problem/10352360> llvm-svn: 143093
-
- Oct 15, 2011
-
-
Andrew Trick authored
I rewrote the algorithm a while back so it doesn't require map lookup, but neglected to change the data structure. This was caught by llvm-gcc self host, not because there's anything special about llvm-gcc, but because it is the only test for nondeterminism we currently have. Unit tests don't work well for everything; we should always try to have a nondeterminism stress test running. Fixes PR11133: llvm-gcc self host .o mismatch after enable-iv-rewrite=false llvm-svn: 142036
-
- Oct 11, 2011
-
-
Andrew Trick authored
IVs. Indvars previously chose randomly between congruent IVs. Now it will bias the decision toward IVs that SCEVExpander likes to create. This was not done to fix any problem, it's just a welcome side effect of factoring code. llvm-svn: 141633
-
- Sep 28, 2011
-
-
Andrew Trick authored
llvm-svn: 140670
-
- Sep 15, 2011
-
-
Andrew Trick authored
llvm-svn: 139842
-
- Sep 13, 2011
-
-
Andrew Trick authored
llvm-svn: 139583
-
Andrew Trick authored
llvm-svn: 139579
-
Andrew Trick authored
llvm-svn: 139574
-
- Sep 12, 2011
-
-
Andrew Trick authored
llvm-svn: 139517
-
- Sep 10, 2011
-
-
Andrew Trick authored
better. Don't immediately give up when an add operation can't be trivially sign/zero-extended within a loop. If it has NSW/NUW flags, generate a new expression with sign extended (non-recurrent) operand. As before, if SCEV says that all sign extends are loop invariant, then we can widen the operation. llvm-svn: 139453
-
- Sep 09, 2011
-
-
Andrew Trick authored
llvm-svn: 139375
-
- Sep 06, 2011
-
-
Andrew Trick authored
llvm-svn: 139169
-
- Aug 26, 2011
-
-
Bill Wendling authored
llvm-svn: 138651
-
- Aug 24, 2011
-
-
Bill Wendling authored
insertion place. llvm-svn: 138473
-
- Aug 10, 2011
-
-
Andrew Trick authored
SimplifyIndVar utility since it is required. llvm-svn: 137202
-
Andrew Trick authored
based on ScalarEvolution without changing the induction variable phis. This utility is the main tool of IndVarSimplifyPass, but the pass also restructures induction variables in strange ways that are sensitive to pass ordering. This provides a way for other loop passes to simplify new uses of induction variables created during transformation. The utility may be used by any pass that preserves ScalarEvolution. Soon LoopUnroll will use it. The net effect in this checkin is to cleanup the IndVarSimplify pass by factoring out the SimplifyIndVar algorithm into a standalone utility. llvm-svn: 137197
-
- Aug 06, 2011
-
-
Andrew Trick authored
recurrence, the initial values low bits can sometimes be ignored. To take advantage of this, added FoldIVUser to IndVarSimplify to fold an IV operand into a udiv/lshr if the operator doesn't affect the result. -indvars -disable-iv-rewrite now transforms i = phi i4 i1 = i0 + 1 idx = i1 >> (2 or more) i4 = i + 4 into i = phi i4 idx = i0 >> ... i4 = i + 4 llvm-svn: 137013
-
- Jul 21, 2011
-
-
Andrew Trick authored
llvm-svn: 135684
-
Chris Lattner authored
to for it to be an an anon namespace and be in a header. Eliminate some extraenous uses of tie. llvm-svn: 135669
-
- Jul 20, 2011
-
-
Jay Foad authored
llvm-svn: 135581
-
Andrew Trick authored
llvm-svn: 135568
-
Andrew Trick authored
info. Holding Use* pointers is bad form even though it happened to work in this case. llvm-svn: 135566
-
Andrew Trick authored
llvm-svn: 135558
-
- Jul 18, 2011
-
-
Andrew Trick authored
llvm-svn: 135426
-
Andrew Trick authored
For -disable-iv-rewrite, perform LFTR without generating a new "canonical" induction variable. Instead find the "best" existing induction variable for use in the loop exit test and compute the final value of that IV for use in the new loop exit test. In short, convert to a simple eq/ne exit test as long as it's cheap to do so. llvm-svn: 135420
-
Andrew Trick authored
not interfere with BackedgeTakenCount computation. llvm-svn: 135412
-
Andrew Trick authored
preheader for the sole purpose of LFTR, since LFTR itself is usually not a clear optimization. llvm-svn: 135409
-
Chris Lattner authored
llvm-svn: 135375
-
- Jul 16, 2011
-
-
Andrew Trick authored
assertion I added in r135333. Check for the existence of a preheader before expanding a recurrence. llvm-svn: 135335
-
Andrew Trick authored
llvm-svn: 135334
-
- Jul 12, 2011
-
-
Andrew Trick authored
LinearFunctionTestReplace rewrite. No functionality. I've been wanting to group the indvar subphases into sections and order them by their logical sequence. My next checkin adds functions related to LFTR, and doing the reorg now should help reviewers. Since, most of the code in IndVarSimplify.cpp has recently been replaced or will be replaced soon, obscuring blame should not be an issue. This seems like an ideal time to shuffle the code around. I'm happy to take more suggestions for cleaning up the code. Or if you've been wanting to cleanup anything in this file yourself, now is a good time. llvm-svn: 134941
-
- Jul 06, 2011
-
-
Andrew Trick authored
careful about referencing values. llvm-svn: 134537
-
Andrew Trick authored
llvm-svn: 134530
-
- Jul 05, 2011
-
-
Devang Patel authored
llvm-svn: 134441
-
Andrew Trick authored
Putting back the helper that I removed on 7/1 to do this right. llvm-svn: 134423
-