aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Add some new instructionsChris Lattner2004-04-111-1/+38
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12838 91177308-0d34-0410-b5e6-96231b3b80d8
* New testcaseChris Lattner2004-04-111-0/+34
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12837 91177308-0d34-0410-b5e6-96231b3b80d8
* Relax assertion to make this function work with a broader class of instructionsChris Lattner2004-04-112-4/+16
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12836 91177308-0d34-0410-b5e6-96231b3b80d8
* Two changes:Chris Lattner2004-04-112-132/+176
| | | | | | | | | | 1. If an incoming argument is dead, don't load it from the stack 2. Do not code gen noop copies at all (ie, cast int -> uint), not even to a move. This should reduce register pressure for allocators that are unable to coallesce away these copies in some cases. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12835 91177308-0d34-0410-b5e6-96231b3b80d8
* Add another variant of the testcaseChris Lattner2004-04-111-0/+15
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12834 91177308-0d34-0410-b5e6-96231b3b80d8
* operator new & operator new[] do not kill any legal memory locations.Chris Lattner2004-04-111-0/+3
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12833 91177308-0d34-0410-b5e6-96231b3b80d8
* new testcaseChris Lattner2004-04-111-0/+12
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12832 91177308-0d34-0410-b5e6-96231b3b80d8
* Allow clients to be more efficient.Chris Lattner2004-04-111-0/+4
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12831 91177308-0d34-0410-b5e6-96231b3b80d8
* Make comments above APIs reflect what they should do.Chris Lattner2004-04-111-7/+7
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12830 91177308-0d34-0410-b5e6-96231b3b80d8
* New method to allow more efficient clientsChris Lattner2004-04-111-0/+9
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12829 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix a bug in my select transformationChris Lattner2004-04-111-2/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12826 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a missing break, which caused a crash in an obscure situationChris Lattner2004-04-111-0/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12825 91177308-0d34-0410-b5e6-96231b3b80d8
* Update the value numbering interface.Chris Lattner2004-04-101-1/+4
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12824 91177308-0d34-0410-b5e6-96231b3b80d8
* Note to self: SAVE FILES!Chris Lattner2004-04-101-0/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12823 91177308-0d34-0410-b5e6-96231b3b80d8
* Add an interface to update value numberingChris Lattner2004-04-101-1/+10
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12822 91177308-0d34-0410-b5e6-96231b3b80d8
* Implement InstCombine/select.ll:test13*Chris Lattner2004-04-101-0/+22
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12821 91177308-0d34-0410-b5e6-96231b3b80d8
* New testcasesChris Lattner2004-04-101-0/+17
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12820 91177308-0d34-0410-b5e6-96231b3b80d8
* Implement InstCombine/add.ll:test20Chris Lattner2004-04-101-4/+14
| | | | | | | Canonicalize add of sign bit constant into a xor git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12819 91177308-0d34-0410-b5e6-96231b3b80d8
* New testcaseChris Lattner2004-04-101-0/+6
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12818 91177308-0d34-0410-b5e6-96231b3b80d8
* Rewrite the GCSE pass to be *substantially* simpler, a bit more efficient,Chris Lattner2004-04-101-214/+121
| | | | | | | and a bit more powerful git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12817 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix spurious warning in release modeChris Lattner2004-04-101-1/+3
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12816 91177308-0d34-0410-b5e6-96231b3b80d8
* Silence a spurious warningChris Lattner2004-04-102-2/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12815 91177308-0d34-0410-b5e6-96231b3b80d8
* Simplify code a bit, and fix a bug that was breaking perlbmkChris Lattner2004-04-101-22/+28
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12814 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix a bug in my checkin last night that was breaking programs using invoke.Chris Lattner2004-04-101-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12813 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix previous patchChris Lattner2004-04-101-7/+5
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12811 91177308-0d34-0410-b5e6-96231b3b80d8
* Correctly update countersChris Lattner2004-04-101-5/+11
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12810 91177308-0d34-0410-b5e6-96231b3b80d8
* Add noteChris Lattner2004-04-101-0/+5
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12809 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a couple of more functions that cannot access memory (the intrinsics) andChris Lattner2004-04-101-0/+7
| | | | | | | don't write to memory git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12808 91177308-0d34-0410-b5e6-96231b3b80d8
* Simplify code a bit, and use alias analysis to allow us to delete unusedChris Lattner2004-04-101-11/+42
| | | | | | | call and invoke instructions that are known to not write to memory. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12807 91177308-0d34-0410-b5e6-96231b3b80d8
* New testcasesChris Lattner2004-04-102-0/+22
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12806 91177308-0d34-0410-b5e6-96231b3b80d8
* Clarify interfaceChris Lattner2004-04-101-2/+4
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12805 91177308-0d34-0410-b5e6-96231b3b80d8
* Create the output directory if it's not already thereChris Lattner2004-04-101-0/+3
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12804 91177308-0d34-0410-b5e6-96231b3b80d8
* Simplify cfg now eliminates all of the branches in this testcaseChris Lattner2004-04-091-0/+15
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12803 91177308-0d34-0410-b5e6-96231b3b80d8
* Another testcaseChris Lattner2004-04-091-0/+8
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12802 91177308-0d34-0410-b5e6-96231b3b80d8
* Testcase to make sure we can apply the shift to the operands of the select,Chris Lattner2004-04-091-0/+13
| | | | | | | eliminating the shifts git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12801 91177308-0d34-0410-b5e6-96231b3b80d8
* Implement select.ll:test12*Chris Lattner2004-04-091-0/+108
| | | | | | | | | | | | | | | | | | | This transforms code like this: %C = or %A, %B %D = select %cond, %C, %A into: %C = select %cond, %B, 0 %D = or %A, %C Since B is often a constant, the select can often be eliminated. In any case, this reduces the usage count of A, allowing subsequent optimizations to happen. This xform applies when the operator is any of: add, sub, mul, or, xor, and, shl, shr git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12800 91177308-0d34-0410-b5e6-96231b3b80d8
* Add testcases for harder combining cases.Chris Lattner2004-04-091-0/+18
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12799 91177308-0d34-0410-b5e6-96231b3b80d8
* Fold code like:Chris Lattner2004-04-091-18/+72
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | if (C) V1 |= V2; into: Vx = V1 | V2; V1 = select C, V1, Vx when the expression can be evaluated unconditionally and is *cheap* to execute. This limited form of if conversion is quite handy in lots of cases. For example, it turns this testcase into straight-line code: int in0 ; int in1 ; int in2 ; int in3 ; int in4 ; int in5 ; int in6 ; int in7 ; int in8 ; int in9 ; int in10; int in11; int in12; int in13; int in14; int in15; long output; void mux(void) { output = (in0 ? 0x00000001 : 0) | (in1 ? 0x00000002 : 0) | (in2 ? 0x00000004 : 0) | (in3 ? 0x00000008 : 0) | (in4 ? 0x00000010 : 0) | (in5 ? 0x00000020 : 0) | (in6 ? 0x00000040 : 0) | (in7 ? 0x00000080 : 0) | (in8 ? 0x00000100 : 0) | (in9 ? 0x00000200 : 0) | (in10 ? 0x00000400 : 0) | (in11 ? 0x00000800 : 0) | (in12 ? 0x00001000 : 0) | (in13 ? 0x00002000 : 0) | (in14 ? 0x00004000 : 0) | (in15 ? 0x00008000 : 0) ; } git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12798 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix an obvious bug in the refactoring I did a few days agoChris Lattner2004-04-091-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12797 91177308-0d34-0410-b5e6-96231b3b80d8
* Expand on adding an intrinsic. Move section to before adding an instructionChris Lattner2004-04-091-26/+40
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12796 91177308-0d34-0410-b5e6-96231b3b80d8
* Reversed the order of the llvm.writeport() operands so that the valueJohn Criswell2004-04-093-14/+14
| | | | | | | is listed first and the address is listed second. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12795 91177308-0d34-0410-b5e6-96231b3b80d8
* Fold binary operators with a constant operand into select instructionsChris Lattner2004-04-091-15/+94
| | | | | | | | that have a constant operand. This implements add.ll:test19, shift.ll:test15*, and others that are not tested git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12794 91177308-0d34-0410-b5e6-96231b3b80d8
* Implement select.ll:test11Chris Lattner2004-04-091-5/+14
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12793 91177308-0d34-0410-b5e6-96231b3b80d8
* new testcaseChris Lattner2004-04-091-0/+7
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12792 91177308-0d34-0410-b5e6-96231b3b80d8
* Add definition list to each live interval.Alkis Evlogimenos2004-04-093-49/+68
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12791 91177308-0d34-0410-b5e6-96231b3b80d8
* Fixed some spelling.John Criswell2004-04-091-4/+4
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12790 91177308-0d34-0410-b5e6-96231b3b80d8
* Modified the prototypes of the llvm.readport and llvm.writeport intrinsicsJohn Criswell2004-04-091-28/+35
| | | | | | | | | | so that they do not specify specific integer sizes (as those are constrained by the code generator, not the intrinsic itself). Also put these intrinsics into their own "Operating System" section. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12789 91177308-0d34-0410-b5e6-96231b3b80d8
* Added the llvm.readport and llvm.writeport intrinsics.John Criswell2004-04-091-0/+91
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12788 91177308-0d34-0410-b5e6-96231b3b80d8
* Changed assertions to error messages.John Criswell2004-04-092-4/+8
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12787 91177308-0d34-0410-b5e6-96231b3b80d8
* Changes recommended by Chris:John Criswell2004-04-083-22/+32
| | | | | | | | | | | | | | | InstSelectSimple.cpp: Change the checks for proper I/O port address size into an exit() instead of an assertion. Assertions aren't used in Release builds, and handling this error should be graceful (not that this counts as graceful, but it's more graceful). Modified the generation of the IN/OUT instructions to have 0 arguments. X86InstrInfo.td: Added the OpSize attribute to the 16 bit IN and OUT instructions. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12786 91177308-0d34-0410-b5e6-96231b3b80d8