summaryrefslogtreecommitdiffstats
path: root/llvm/test/Transforms/IndVarSimplify
Commit message (Collapse)AuthorAgeFilesLines
...
* Test case for r140670: indvars should hoist sext.Andrew Trick2011-09-281-0/+28
| | | | llvm-svn: 140671
* Stop emitting instructions with the name "tmp" they eat up memory and have ↵Benjamin Kramer2011-09-271-1/+1
| | | | | | | | to be uniqued, without any benefit. If someone prefers %tmp42 to %42, run instnamer. llvm-svn: 140634
* [indvars] Fix PR10946: SCEV cannot handle Vector IVs.Andrew Trick2011-09-191-0/+16
| | | | llvm-svn: 140026
* Reapply r139759. Disable IV rewriting by default. See PR10916.Andrew Trick2011-09-151-1/+1
| | | | llvm-svn: 139842
* [indvars] Revert r139579 until 401.bzip -arch i386 miscompilation is fixed. ↵Andrew Trick2011-09-131-1/+1
| | | | | | PR10920. llvm-svn: 139583
* Disable IV rewriting by default. See PR10916.Andrew Trick2011-09-131-1/+1
| | | | llvm-svn: 139579
* [indvars] Fix bugs in floating point IV range checks noticed by inspection.Andrew Trick2011-09-131-3/+3
| | | | llvm-svn: 139574
* Conditionalize indvars test that relies on SCEV expansion of geps,Andrew Trick2011-09-121-4/+13
| | | | | | which is only relevant with canonical IVs llvm-svn: 139556
* indvars test only relevant for -enable-iv-rewrite.Andrew Trick2011-09-121-1/+3
| | | | | | Otherwise this case is now covered by no-iv-rewrite.ll. llvm-svn: 139552
* Conditionalize indvars tests that rely on SCEV expansion of geps,Andrew Trick2011-09-125-25/+26
| | | | | | | which is relevant with canonical IVs. Anything else being checked by these tests is already covered by early CSE. llvm-svn: 139535
* Removing indvars tests that directly test canonical IVs and nothing else.Andrew Trick2011-09-126-137/+0
| | | | llvm-svn: 139518
* Rename -disable-iv-rewrite to -enable-iv-rewrite=false in preparation for ↵Andrew Trick2011-09-129-9/+9
| | | | | | default change. llvm-svn: 139517
* Test case for r139453, WidenIV::GetExtendedOperandRecurrence.Andrew Trick2011-09-121-0/+30
| | | | llvm-svn: 139504
* Update to new EH scheme.Bill Wendling2011-09-015-3/+27
| | | | llvm-svn: 138927
* Don't sink landingpad instructions during ind-var simplification.Bill Wendling2011-08-261-0/+32
| | | | llvm-svn: 138651
* Made SCEV's UDiv expressions more canonical. When dividing aAndrew Trick2011-08-061-0/+56
| | | | | | | | | | | | | | | | | | | | | | | 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
* indvars: Added getInsertPointForUses to find a valid place to truncate the IV.Andrew Trick2011-07-201-0/+39
| | | | llvm-svn: 135568
* indvars test case for r135558.Andrew Trick2011-07-201-0/+7
| | | | llvm-svn: 135559
* indvars -disable-iv-rewrite fix: derived GEP IVsAndrew Trick2011-07-201-6/+29
| | | | llvm-svn: 135558
* indvars: LinearFunctionTestReplace for non-canonical IVs.Andrew Trick2011-07-182-3/+232
| | | | | | | | | | 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
* indvars -disable-iv-rewrite: Added SimplifyCongruentIVs.Andrew Trick2011-07-062-4/+55
| | | | llvm-svn: 134530
* indvars -disable-iv-rewrite: bug fix involving weird geps and related cleanup.Andrew Trick2011-07-022-4/+30
| | | | llvm-svn: 134306
* indvars -disable-iv-rewrite: handle cloning binary operators that cannot ↵Andrew Trick2011-06-301-4/+38
| | | | | | overflow. llvm-svn: 134177
* indvars -disable-iv-rewrite: handle an edge case involving identity phis.Andrew Trick2011-06-301-7/+32
| | | | llvm-svn: 134124
* indvars -disable-iv-rewrite: insert new trunc instructions carefully.Andrew Trick2011-06-291-2/+31
| | | | llvm-svn: 134112
* indvars -disable-iv-rewrite: just because SCEV ignores casts doesn'tAndrew Trick2011-06-291-0/+37
| | | | | | mean they can be removed. llvm-svn: 134054
* FileCheckify and prepare for -disable-iv-rewrite.Andrew Trick2011-06-281-7/+11
| | | | llvm-svn: 133998
* indvars -disable-iv-rewrite: Adds support for eliminating identityAndrew Trick2011-06-211-0/+1
| | | | | | | | | | | | | | | | | | | ops. This is a rewrite of the IV simplification algorithm used by -disable-iv-rewrite. To avoid perturbing the default mode, I temporarily split the driver and created SimplifyIVUsersNoRewrite. The idea is to avoid doing opcode/pattern matching inside IndVarSimplify. SCEV already does it. We want to optimize with the full generality of SCEV, but optimize def-use chains top down on-demand rather than rewriting the entire expression bottom-up. This was easy to do for operations that SCEV can prove are identity function. So we're now eliminating bitmasks and zero extends this way. A result of this rewrite is that indvars -disable-iv-rewrite no longer requires IVUsers. llvm-svn: 133502
* manually upgrade a bunch of tests to modern syntax, and remove some thatChris Lattner2011-06-171-1/+1
| | | | | | are either unreduced or only test old syntax. llvm-svn: 133228
* Test case pasto (failed when run with IR verifier).Andrew Trick2011-06-021-2/+2
| | | | llvm-svn: 132516
* scev: Better sign-extend removal. Normalize postincrement recurrencesAndrew Trick2011-05-311-17/+12
| | | | | | so that their sign extended forms are congruent when no overflow occurs. llvm-svn: 132360
* indvars: incremental fixes for -disable-iv-rewrite and testcases.Andrew Trick2011-05-261-1/+66
| | | | | | | | Use a proper worklist for use-def traversal without holding onto an iterator. Now that we process all IV uses, we need complete logic for resusing existing derived IV defs. See HoistStep. llvm-svn: 132103
* indvars: fixed IV cloning in -disable-iv-rewrite mode with associatedAndrew Trick2011-05-252-0/+216
| | | | | | cleanup and overdue test cases. llvm-svn: 132038
* FileCheck-ize a couple of IV unit tests.Andrew Trick2011-05-242-7/+13
| | | | llvm-svn: 131946
* Test case for r130799 - indvars: Added canExpandBackEdgeTakenCount.Andrew Trick2011-05-241-1/+5
| | | | llvm-svn: 131939
* Fixes PR9730: indvars: An asserting value handle still pointed to this valueAndrew Trick2011-04-271-5/+6
| | | | | | | | | Modified LinearFunctionTestReplace to push the condition on the dead list instead of eagerly deleting it. This can cause unnecessary IV rewrites, which should have no effect on codegen and will not be an issue once we stop generating canonical IVs. llvm-svn: 130340
* Avoid creating canonical induction variables for non-native types.Andrew Trick2011-03-1813-13/+13
| | | | | | | | For example, on 32-bit architecture, don't promote all uses of the IV to 64-bits just because one use is a 64-bit cast. Alternate implementation of the patch by Arnaud de Grandmaison. llvm-svn: 127884
* Remove LoopIndexSplit pass. It is neither maintained nor used by anyone.Devang Patel2010-10-071-33/+0
| | | | llvm-svn: 116004
* more test cleanupChris Lattner2010-09-021-24/+0
| | | | llvm-svn: 112892
* Print the number of uses of a function in the .ll since it can be informativeDuncan Sands2010-09-021-2/+1
| | | | | | and there seems to be no reason not to. llvm-svn: 112812
* Correct bogus module triple specifications.Duncan Sands2010-08-302-2/+2
| | | | llvm-svn: 112469
* Fix SCEVExpander::visitAddRecExpr so that it remembers the induction variableDan Gohman2010-07-261-0/+36
| | | | | | | | it inserted rather than using LoopInfo::getCanonicalInductionVariable to rediscover it, since that doesn't work on non-canonical loops. This fixes infinite recurrsion on such loops; PR7562. llvm-svn: 109419
* Fix this test.Dan Gohman2010-07-161-1/+1
| | | | llvm-svn: 108491
* Fix the order that SCEVExpander considers add operands in so thatDan Gohman2010-07-151-0/+40
| | | | | | | it doesn't miss an opportunity to form a GEP, regardless of the relative loop depths of the operands. This fixes rdar://8197217. llvm-svn: 108475
* Fix ScalarEvolution's tripcount computation for chains of loopsDan Gohman2010-06-291-2/+64
| | | | | | | where each loop's induction variable's start value is the exit value of a preceding loop. llvm-svn: 107224
* Disable indvars on loops when LoopSimplify form is not available.Dan Gohman2010-06-181-1/+18
| | | | | | This fixes PR7333. llvm-svn: 106267
* Remove arm_apcscc from the test files. It is the default and doing thisRafael Espindola2010-06-171-1/+1
| | | | | | matches what llvm-gcc and clang now produce. llvm-svn: 106221
* Remove the Expr member from IVUsers. Instead of remembering the expression,Dan Gohman2010-04-191-0/+24
| | | | | | | just ask ScalarEvolution for it on demand. This helps IVUsers be more robust in the case of expressions changing underneath it. This fixes PR6862. llvm-svn: 101819
* Fix declarations in a few more tests.Nick Lewycky2010-04-171-1/+1
| | | | llvm-svn: 101676
* Teach ScalarEvolution to simplify smax and umax when it can proveDan Gohman2010-04-131-0/+52
| | | | | | that one operand is always greater than another. llvm-svn: 101142
OpenPOWER on IntegriCloud