summaryrefslogtreecommitdiff
path: root/lib/Transforms
Commit message (Collapse)AuthorAge
...
* Generalize not and neg comparison testers to allow constant to be considered ↵Chris Lattner2003-03-10
| | | | | | | | | | | | | | | | | | | | | not'able and neg'able. This allows optimization of this: int %test4(int %A, int %B) { %a = xor int %A, -1 %c = and int %a, 5 ; 5 = ~c2 %d = xor int %c, -1 ret int %d } into this: int %test4(int %A, int %B) { ; No predecessors! %c.demorgan = or int %A, -6 ; <int> [#uses=1] ret int %c.demorgan } git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5736 91177308-0d34-0410-b5e6-96231b3b80d8
* Generalize (A+c1)+c2 optimization to work with all associative operatorsChris Lattner2003-03-10
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5733 91177308-0d34-0410-b5e6-96231b3b80d8
* Minor change, no functionality diffChris Lattner2003-03-10
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5731 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix bug: (x << 100) wasn't folded to 0, but (x >> 100) was (when x is unsigned)Chris Lattner2003-03-10
| | | | | | | Implement new shift optimizations for shifting the result of a shift. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5729 91177308-0d34-0410-b5e6-96231b3b80d8
* Implement: (A|B)^B == A & (~B)Chris Lattner2003-03-10
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5728 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix bug: SimplifyCFG/2003-03-07-DominateProblem.llChris Lattner2003-03-07
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5722 91177308-0d34-0410-b5e6-96231b3b80d8
* Implement %test7 in InstCombine/getelementptr.llChris Lattner2003-03-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5704 91177308-0d34-0410-b5e6-96231b3b80d8
* Implement CFGSimplify/PhiBlockMerge*.llChris Lattner2003-03-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5702 91177308-0d34-0410-b5e6-96231b3b80d8
* Implement testcase CFGSimplify/EqualPHIEdgeBlockMerge.llChris Lattner2003-03-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5699 91177308-0d34-0410-b5e6-96231b3b80d8
* Convert LICM over to use AliasSetTracker. Besides being nicer, this ↵Chris Lattner2003-03-03
| | | | | | | | | automatically allows LICM to use access sizes to help alias analysis be more precise. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5693 91177308-0d34-0410-b5e6-96231b3b80d8
* Eliminate tons of bogus warningsChris Lattner2003-03-03
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5686 91177308-0d34-0410-b5e6-96231b3b80d8
* Change the mem2reg interface to accept a TargetData argumentChris Lattner2003-03-03
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5685 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix bug: LICM/2003-02-28-PromoteDifferentType.llChris Lattner2003-02-28
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5675 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix bug I introduced yesterday :(Chris Lattner2003-02-28
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5669 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix bug: LICM/2003-02-27-PreheaderExitNodeUpdate.llChris Lattner2003-02-28
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5667 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix bug: 2003-02-27-PreheaderExitNodeUpdate.ll by updating exit node infoChris Lattner2003-02-27
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5664 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a new assertion to check that stuff is happening rightChris Lattner2003-02-27
| | | | | | | | Ironically the exit block modification code wasn't updating the exit block information itself. Fix this. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5659 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix bug: 2003-02-27-StoreSinkPHIs.llChris Lattner2003-02-27
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5658 91177308-0d34-0410-b5e6-96231b3b80d8
* * Don't forget to update Loop information!Chris Lattner2003-02-27
| | | | | | | | | * Remove bogus assertion: there may be a single outside predecessor and still need a new loop-preheader if the predecessor has multiple successors. See bug: LICM/2003-02-27-PreheaderProblem.ll git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5655 91177308-0d34-0410-b5e6-96231b3b80d8
* Replace assertion with a handler.Chris Lattner2003-02-27
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5653 91177308-0d34-0410-b5e6-96231b3b80d8
* * Significant changes to the preheader insertion pass:Chris Lattner2003-02-27
| | | | | | | | | | - Now we perform loop exit-block splitting to ensure exit blocks are always dominated by the loop header. - We now preserve dominance frontier information - This fixes bug: LICM/2003-02-26-LoopExitNotDominated.ll git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5652 91177308-0d34-0410-b5e6-96231b3b80d8
* Convert to work with new AliasAnalysis interface by conservatively assuming ↵Chris Lattner2003-02-26
| | | | | | all pointers are arbitrarily large accesses git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5636 91177308-0d34-0410-b5e6-96231b3b80d8
* Rename Instruction::hasSideEffects() -> mayWriteToMemory()Chris Lattner2003-02-24
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5620 91177308-0d34-0410-b5e6-96231b3b80d8
* Initial implementation of Loop invariant memory->scalar promotionChris Lattner2003-02-24
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5613 91177308-0d34-0410-b5e6-96231b3b80d8
* Split mem2reg promotion into two parts: a function which does the work, andChris Lattner2003-02-22
| | | | | | | a pass which wraps the function. This allows other passes to use the functionality git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5610 91177308-0d34-0410-b5e6-96231b3b80d8
* Clean up std namespace referencesChris Lattner2003-02-22
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5608 91177308-0d34-0410-b5e6-96231b3b80d8
* 4 new transformations:Chris Lattner2003-02-18
| | | | | | | | | | * X*C + X --> X * (C+1) * X + X*C --> X * (C+1) * X - X*C --> X * (1-C) * X*C - X --> X * (C-1) git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5592 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a variety of new transformations:Chris Lattner2003-02-18
| | | | | | | | | | | | | | | | | * A & ~A == 0 * A / (2^c) == A >> c if unsigned * 0 / A == 0 * 1.0 * A == A * A * (2^c) == A << c * A ^ ~A == -1 * A | ~A == -1 * 0 % X = 0 * A % (2^c) == A & (c-1) if unsigned * A - (A & B) == A & ~B * -1 - A == ~A git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5587 91177308-0d34-0410-b5e6-96231b3b80d8
* Changes to runtime frameworkAnand Shukla2003-02-14
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5572 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix a bug that cause a crash resolving questionable function callsChris Lattner2003-02-14
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5567 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix a misunderstanding of the standard associative containersChris Lattner2003-02-14
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5565 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix bug: LevelRaise/2003-02-13-CallRaise.llChris Lattner2003-02-14
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5562 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert Anand's patch which broke the buildChris Lattner2003-02-10
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5525 91177308-0d34-0410-b5e6-96231b3b80d8
* *** empty log message ***Anand Shukla2003-02-09
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5522 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix a problem Sumant was running intoChris Lattner2003-02-06
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5499 91177308-0d34-0410-b5e6-96231b3b80d8
* Split public interface out into header fileChris Lattner2003-02-03
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5472 91177308-0d34-0410-b5e6-96231b3b80d8
* Change DSGraph stuff to use hash_(set|map) instead of std::(set|map)Chris Lattner2003-02-01
| | | | | | | This change provides a small (3%) but consistent speedup git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5460 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix typoChris Lattner2003-02-01
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5458 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix a bug resolving sprintf(...) to sprintf(char*, char*, ...)Chris Lattner2003-01-30
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5446 91177308-0d34-0410-b5e6-96231b3b80d8
* Actually print the function _name_ if there is a problemChris Lattner2003-01-30
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5443 91177308-0d34-0410-b5e6-96231b3b80d8
* * Fix linking of opaque types and their non-opaque versionsChris Lattner2003-01-30
| | | | | | | * Fix bug: Linker/2003-01-30-LinkerTypeRename.ll git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5441 91177308-0d34-0410-b5e6-96231b3b80d8
* Eliminate using declsChris Lattner2003-01-30
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5439 91177308-0d34-0410-b5e6-96231b3b80d8
* * Fix function resolution for varargs function to generate incorrect ↵Chris Lattner2003-01-30
| | | | | | | | | | bytecode instead of crashing * remove using decls CVS: ---------------------------------------------------------------------- git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5437 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix levelraise/2003-01-30-ShiftCrash.llChris Lattner2003-01-30
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5435 91177308-0d34-0410-b5e6-96231b3b80d8
* Initial checkin of pool allocation codeChris Lattner2003-01-29
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5432 91177308-0d34-0410-b5e6-96231b3b80d8
* Disable construction of pool allocatorChris Lattner2003-01-24
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5422 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix bug: LevelRaise/2003-01-22-GEPProblem.llChris Lattner2003-01-23
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5407 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix bug: ADCE/2003-01-22-PredecessorProblem.llChris Lattner2003-01-23
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5405 91177308-0d34-0410-b5e6-96231b3b80d8
* Rename include/llvm/Transforms/Instrumentation/TraceFunctions.h to ↵Chris Lattner2003-01-14
| | | | | | Instrumentation.h git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5281 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix typeoChris Lattner2003-01-14
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5278 91177308-0d34-0410-b5e6-96231b3b80d8