summaryrefslogtreecommitdiffstats
path: root/llvm/lib
Commit message (Collapse)AuthorAgeFilesLines
* Implement scanf and fix sscanf to actually endian swap the results correctlyChris Lattner2003-03-311-2/+97
| | | | llvm-svn: 5763
* Initial checkin of PRE on LLVM. This implementation is still lacking inChris Lattner2003-03-311-0/+614
| | | | | | | | | | | | | | | several ways: * Load expressions are not PRE'd well. Alias Analysis should be used to get accurate information when computing anticipatibility. * The expression collection implementation does not handle PHI nodes properly, thus the implementation misses many opportunities to PRE. * This code could be sped up quite a bit Despite these flaws, the code seems to work well, and handles PR's as one would expect. llvm-svn: 5759
* * We now preserve the no-critical-edge pass (because we cannot insert ↵Chris Lattner2003-03-311-11/+17
| | | | | | | | critical edges) * Small modification to be more efficient llvm-svn: 5757
* *** empty log message ***Guochun Shi2003-03-275-0/+2726
| | | | llvm-svn: 5755
* Move BreakCriticalEdges pass to lib/Transforms/UtilsChris Lattner2003-03-211-155/+0
| | | | llvm-svn: 5754
* Add helper methodChris Lattner2003-03-211-0/+4
| | | | llvm-svn: 5753
* * Change the order that globals and constants are processed inChris Lattner2003-03-191-36/+45
| | | | | | * Add support for implicit zero initializers llvm-svn: 5750
* Changes to the V2 bytecode format:Chris Lattner2003-03-193-48/+54
| | | | | | | | | | | | | | | | | | | | - Null values are implicitly encoded instead of explicitly, this makes things more compact! - More compactly represent ConstantPointerRefs - Bytecode files are represented as: Header|GlobalTypes|GlobalVars/Function Protos|Constants|Functions|SymTab instead of Header|GlobalTypes|Constants|GlobalVars/Function Protos|Functions|SymTab which makes a lot of things simpler. Writer changes: - We now explictly encode versioning information in the bytecode files. - This allows new code to read bytecode files produced by old code, but new bytecode files can have enhancements such as the above. Although this makes the reader a bit more complex (having to deal with old formats), the writer only needs to be able to produce the most recent version. llvm-svn: 5749
* * Bug fixes:Chris Lattner2003-03-193-172/+207
| | | | | | | | | | | | | | | | | | | | | - Fix problems where the constant table would not get updated when resolving constants causes other constants to change. Changes to the V2 bytecode format - Null values are implicitly encoded instead of explicitly, this makes things more compact! - More compactly represent ConstantPointerRefs - Bytecode files are represented as: Header|GlobalTypes|GlobalVars/Function Protos|Constants|Functions|SymTab instead of Header|GlobalTypes|Constants|GlobalVars/Function Protos|Functions|SymTab which makes a lot of things simpler. Changes to the reader: - Function loading code is much simpler. We now no longer make function PlaceHolderHelper objects to be replaced with real functions. llvm-svn: 5748
* Add the following instcombine xforms:Chris Lattner2003-03-111-29/+74
| | | | | | | | - Implement simple reassociation: (A|c1)|(B|c2) == (A|B)|(c1|c2) - (A & C1)+(B & C2) -> (A & C1)|(B & C2) iff C1&C2 == 0 - (A & C1)^(B & C2) -> (A & C1)|(B & C2) iff C1&C2 == 0 llvm-svn: 5743
* Implement: -A*-B == A*BChris Lattner2003-03-101-0/+4
| | | | llvm-svn: 5740
* Add new transformation: // (~A | ~B) == (~(A & B))Chris Lattner2003-03-101-8/+19
| | | | llvm-svn: 5738
* Generalize not and neg comparison testers to allow constant to be considered ↵Chris Lattner2003-03-101-27/+41
| | | | | | | | | | | | | | | | | | | | 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 } llvm-svn: 5736
* Fix ConstantUInt::isAllOnesValueChris Lattner2003-03-101-0/+7
| | | | llvm-svn: 5734
* Generalize (A+c1)+c2 optimization to work with all associative operatorsChris Lattner2003-03-101-35/+50
| | | | llvm-svn: 5733
* Minor change, no functionality diffChris Lattner2003-03-101-3/+3
| | | | llvm-svn: 5731
* Fix bug: (x << 100) wasn't folded to 0, but (x >> 100) was (when x is unsigned)Chris Lattner2003-03-101-7/+48
| | | | | | Implement new shift optimizations for shifting the result of a shift. llvm-svn: 5729
* Implement: (A|B)^B == A & (~B)Chris Lattner2003-03-101-0/+25
| | | | llvm-svn: 5728
* Fix bug: SimplifyCFG/2003-03-07-DominateProblem.llChris Lattner2003-03-071-2/+19
| | | | llvm-svn: 5722
* Clean up cruftChris Lattner2003-03-061-4/+1
| | | | llvm-svn: 5720
* Remove #includeChris Lattner2003-03-061-1/+18
| | | | | | Extend getNullValue to work with struct and array types llvm-svn: 5718
* Infrastructure for more compact bytecode files and REAL support for versioningChris Lattner2003-03-062-9/+47
| | | | llvm-svn: 5716
* s/Method/Function in variable and method namesChris Lattner2003-03-063-16/+16
| | | | llvm-svn: 5715
* Continue simplifying error handling, s/method/functionChris Lattner2003-03-062-60/+48
| | | | llvm-svn: 5714
* Cleanup error handling constructsChris Lattner2003-03-061-37/+47
| | | | llvm-svn: 5713
* Pull common code outChris Lattner2003-03-061-16/+14
| | | | llvm-svn: 5712
* Remove unneccesary forward declChris Lattner2003-03-061-1/+1
| | | | llvm-svn: 5710
* Use the std namespace explicitlyChris Lattner2003-03-063-47/+41
| | | | llvm-svn: 5708
* Implement %test7 in InstCombine/getelementptr.llChris Lattner2003-03-051-7/+21
| | | | llvm-svn: 5704
* Implement CFGSimplify/PhiBlockMerge*.llChris Lattner2003-03-051-10/+36
| | | | llvm-svn: 5702
* Simplify some of the PHI node interfacesChris Lattner2003-03-051-14/+5
| | | | llvm-svn: 5700
* Implement testcase CFGSimplify/EqualPHIEdgeBlockMerge.llChris Lattner2003-03-051-10/+24
| | | | llvm-svn: 5699
* Fix bug: BasicAA/2003-03-04-GEPCrash.llChris Lattner2003-03-041-17/+11
| | | | llvm-svn: 5695
* Convert LICM over to use AliasSetTracker. Besides being nicer, this ↵Chris Lattner2003-03-031-164/+45
| | | | | | | | automatically allows LICM to use access sizes to help alias analysis be more precise. llvm-svn: 5693
* Fix bug: Assembler/2003-03-03-DuplicateConstant.llChris Lattner2003-03-031-4/+6
| | | | llvm-svn: 5692
* ADd two new 'add' methodsChris Lattner2003-03-031-0/+28
| | | | llvm-svn: 5691
* Eliminate tons of bogus warningsChris Lattner2003-03-031-8/+10
| | | | llvm-svn: 5686
* Change the mem2reg interface to accept a TargetData argumentChris Lattner2003-03-033-9/+19
| | | | llvm-svn: 5685
* Don't apply type information to load instructions if it will cause collapsingChris Lattner2003-03-032-6/+7
| | | | llvm-svn: 5684
* Fix a problem with negative indexesChris Lattner2003-03-021-3/+3
| | | | llvm-svn: 5681
* Fix bug: LICM/2003-02-28-PromoteDifferentType.llChris Lattner2003-02-281-2/+8
| | | | llvm-svn: 5675
* Add dump method for LoopsChris Lattner2003-02-281-0/+4
| | | | llvm-svn: 5671
* Fix bug I introduced yesterday :(Chris Lattner2003-02-281-1/+2
| | | | llvm-svn: 5669
* Fix bug: LICM/2003-02-27-PreheaderExitNodeUpdate.llChris Lattner2003-02-281-1/+5
| | | | llvm-svn: 5667
* Fix bug: 2003-02-27-PreheaderExitNodeUpdate.ll by updating exit node infoChris Lattner2003-02-271-0/+16
| | | | llvm-svn: 5664
* Simplify a bit by using a new member functionChris Lattner2003-02-271-6/+3
| | | | llvm-svn: 5662
* Change behavior of changeExitBlock function to replace all instances of exit ↵Chris Lattner2003-02-271-2/+8
| | | | | | block llvm-svn: 5661
* Add a new assertion to check that stuff is happening rightChris Lattner2003-02-271-3/+8
| | | | | | | Ironically the exit block modification code wasn't updating the exit block information itself. Fix this. llvm-svn: 5659
* Fix bug: 2003-02-27-StoreSinkPHIs.llChris Lattner2003-02-271-1/+4
| | | | llvm-svn: 5658
* Fix bug: LICM/2003-02-27-PreheaderProblem.llChris Lattner2003-02-271-0/+7
| | | | | | | | There may be a single outside predecessor and still need a new loop-preheader if the predecessor has multiple successors. llvm-svn: 5656
OpenPOWER on IntegriCloud