aboutsummaryrefslogtreecommitdiffstats
path: root/test
Commit message (Collapse)AuthorAgeFilesLines
* Fix a warning.Chris Lattner2008-06-201-3/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52528 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix an error handling redefinition of linkonce functions where theChris Lattner2008-06-202-1/+9
| | | | | | | types differ. Patch by Nathan Keynes! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52527 91177308-0d34-0410-b5e6-96231b3b80d8
* fix a warning.Chris Lattner2008-06-201-4/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52526 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix PR2471, which is a bug involving an invalid promotion from a conditional ↵Chris Lattner2008-06-201-0/+16
| | | | | | load. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52525 91177308-0d34-0410-b5e6-96231b3b80d8
* ISD::UNDEF should be expanded recursively / iteratively.Evan Cheng2008-06-191-0/+6
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52508 91177308-0d34-0410-b5e6-96231b3b80d8
* Modify some ipconstprop tests to also test with invokes.Matthijs Kooijman2008-06-192-2/+13
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52491 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix a bug with <8 x i16> shuffle lowering on X86 where parts of the Eli Friedman2008-06-191-0/+10
| | | | | | | | | | | | shuffle could be skipped. The check is invalid because the loop index i doesn't correspond to the element actually inserted. The correct check is already done a few lines earlier, for whether the element is already in the right spot, so this shouldn't have any effect on the codegen for code that was already correct. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52486 91177308-0d34-0410-b5e6-96231b3b80d8
* New test case.Evan Cheng2008-06-191-0/+17
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52483 91177308-0d34-0410-b5e6-96231b3b80d8
* This also got better (55 - 51 instructions). But doing one more ↵Evan Cheng2008-06-191-1/+1
| | | | | | re-materialization. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52482 91177308-0d34-0410-b5e6-96231b3b80d8
* This got better.Evan Cheng2008-06-191-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52481 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove this test until the corresponding patch is reapplied because it's ↵Owen Anderson2008-06-181-39/+0
| | | | | | causing make check to crash for some people. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52473 91177308-0d34-0410-b5e6-96231b3b80d8
* Add local PRE to GVN. This only operates in cases where it would not ↵Owen Anderson2008-06-181-0/+18
| | | | | | | | | increase code size, namely when the instantiated expression would only need to be created in one predecessor. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52471 91177308-0d34-0410-b5e6-96231b3b80d8
* Rewrite the DeadArgumentElimination pass, to use a more explicit tracking ofMatthijs Kooijman2008-06-181-0/+39
| | | | | | | | | | | | | | dependencies between return values and/or arguments. Also make the handling of arguments and return values the same. The pass now looks properly inside returned structs, but only at the first level (ie, not inside nested structs). Also add a testcase for testing various variations of (multiple) dead rerturn values. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52459 91177308-0d34-0410-b5e6-96231b3b80d8
* Reapply r52397 (make IPConstProp promote returned arguments), but fixed thisMatthijs Kooijman2008-06-181-0/+46
| | | | | | | | | time. Sorry for the trouble! This time, also add a testcase, which I should have done in the first place... git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52455 91177308-0d34-0410-b5e6-96231b3b80d8
* Reapply r52396, it was unrelated to the breakage (that was caused by r52397, myMatthijs Kooijman2008-06-181-9/+30
| | | | | | | commit after this). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52453 91177308-0d34-0410-b5e6-96231b3b80d8
* implement some simple bswap optimizations, rdar://5992453Chris Lattner2008-06-181-4/+27
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52442 91177308-0d34-0410-b5e6-96231b3b80d8
* temporarily revert this testcase since its patch was reverted.Chris Lattner2008-06-181-30/+9
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52441 91177308-0d34-0410-b5e6-96231b3b80d8
* make truncate/sext elimination capable of changing phi's. This Chris Lattner2008-06-181-2/+15
| | | | | | | implements rdar://6013816 and the testcase in Transforms/InstCombine/sext-misc.ll. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52440 91177308-0d34-0410-b5e6-96231b3b80d8
* Preserve dominance frontier while trivially unswitching loop.Devang Patel2008-06-181-0/+22
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52438 91177308-0d34-0410-b5e6-96231b3b80d8
* Learn IPConstProp to look at individual return values and propagate themMatthijs Kooijman2008-06-171-9/+30
| | | | | | | | | | | | individually. Also learn IPConstProp how returning first class aggregates work, in addition to old style multiple return instructions. Modify the return-constants testscase to confirm this behaviour. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52396 91177308-0d34-0410-b5e6-96231b3b80d8
* Do not issue identity copies.Evan Cheng2008-06-161-0/+14
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52373 91177308-0d34-0410-b5e6-96231b3b80d8
* Refine the change in r52258 for avoiding use-before-def conditionsDan Gohman2008-06-162-3/+31
| | | | | | | | | | when changing the stride of a comparison so that it's slightly more precise, by having it scan the instruction list to determine if there is a use of the condition after the point where the condition will be inserted. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52371 91177308-0d34-0410-b5e6-96231b3b80d8
* - Add "Commutative" property to intrinsics. This allows tblgen to generate ↵Evan Cheng2008-06-161-0/+15
| | | | | | | | | the commuted variants for dagisel matching code. - Mark lots of X86 intrinsics as "Commutative" to allow load folding. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52353 91177308-0d34-0410-b5e6-96231b3b80d8
* Make testcase check for extractvalue instead of extractelement.Matthijs Kooijman2008-06-161-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52317 91177308-0d34-0410-b5e6-96231b3b80d8
* Store the result of multiple identical run lines in a temporary file.Matthijs Kooijman2008-06-161-5/+6
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52314 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix PR numbers, I accidentally switched two digits.Matthijs Kooijman2008-06-165-5/+5
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52311 91177308-0d34-0410-b5e6-96231b3b80d8
* If we are checking to see if the result of a call aliases aChris Lattner2008-06-161-0/+23
| | | | | | | | pointer derived from a local allocation, if the local allocation never escapes, the pointers can't alias. This implements PR2436 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52301 91177308-0d34-0410-b5e6-96231b3b80d8
* this is unneeded now.Chris Lattner2008-06-161-3/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52298 91177308-0d34-0410-b5e6-96231b3b80d8
* resolve PR2453 by adding a run line.Chris Lattner2008-06-161-2/+3
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52296 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix PR2434. When scanning for exising binary operator to reuse don't Wojciech Matyjewicz2008-06-151-0/+17
| | | | | | | | | | | | take into account the instrucion pointed by InsertPt. Thanks to it, returning the new value of InsertPt to the InsertBinop() caller can be avoided. The bug was, actually, in visitAddRecExpr() method which wasn't correctly handling changes of InsertPt. There shouldn't be any performance regression, as -gvn pass (run after -indvars) removes any redundant binops. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52291 91177308-0d34-0410-b5e6-96231b3b80d8
* Teach the spiller to commute instructions in order to fold a reload. This ↵Evan Cheng2008-06-131-0/+42
| | | | | | hits 410 times on 444.namd and 122 times on 252.eon. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52266 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove unnecessary target lines.Eli Friedman2008-06-131-2/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52261 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove unnecessary target lines.Eli Friedman2008-06-131-2/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52260 91177308-0d34-0410-b5e6-96231b3b80d8
* Don't skip over instructions other than loads that might read memory Eli Friedman2008-06-131-0/+19
| | | | | | | | when trying to sink stores. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52259 91177308-0d34-0410-b5e6-96231b3b80d8
* Protect ChangeCompareStride from situations in which it is possibleDan Gohman2008-06-131-0/+20
| | | | | | | for it to generate use-before-def IR, such as in this testcase. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52258 91177308-0d34-0410-b5e6-96231b3b80d8
* Make sure SimplifyStoreAtEndOfBlock doesn't mess with loops; the Eli Friedman2008-06-131-0/+22
| | | | | | | | | structure checks are incorrect if the blocks aren't distinct. Fixes PR2435. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52257 91177308-0d34-0410-b5e6-96231b3b80d8
* Disable some DAG combiner optimizations that may beDuncan Sands2008-06-132-0/+45
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | wrong for volatile loads and stores. In fact this is almost all of them! There are three types of problems: (1) it is wrong to change the width of a volatile memory access. These may be used to do memory mapped i/o, in which case a load can have an effect even if the result is not used. Consider loading an i32 but only using the lower 8 bits. It is wrong to change this into a load of an i8, because you are no longer tickling the other three bytes. It is also unwise to make a load/store wider. For example, changing an i16 load into an i32 load is wrong no matter how aligned things are, since the fact of loading an additional 2 bytes can have i/o side-effects. (2) it is wrong to change the number of volatile load/stores: they may be counted by the hardware. (3) it is wrong to change a volatile load/store that requires one memory access into one that requires several. For example on x86-32, you can store a double in one processor operation, but to store an i64 requires two (two i32 stores). In a multi-threaded program you may want to bitcast an i64 to a double and store as a double because that will occur atomically, and be indivisible to other threads. So it would be wrong to convert the store-of-double into a store of an i64, because this will become two i32 stores - no longer atomic. My policy here is to say that the number of processor operations for an illegal operation is undefined. So it is alright to change a store of an i64 (requires at least two stores; but could be validly lowered to memcpy for example) into a store of double (one processor op). In short, if the new store is legal and has the same size then I say that the transform is ok. It would also be possible to say that transforms are always ok if before they were illegal, whether after they are illegal or not, but that's more awkward to do and I doubt it buys us anything much. However this exposed an interesting thing - on x86-32 a store of i64 is considered legal! That is because operations are marked legal by default, regardless of whether the type is legal or not. In some ways this is clever: before type legalization this means that operations on illegal types are considered legal; after type legalization there are no illegal types so now operations are only legal if they really are. But I consider this to be too cunning for mere mortals. Better to do things explicitly by testing AfterLegalize. So I have changed things so that operations with illegal types are considered illegal - indeed they can never map to a machine operation. However this means that the DAG combiner is more conservative because before it was "accidentally" performing transforms where the type was illegal because the operation was nonetheless marked legal. So in a few such places I added a check on AfterLegalize, which I suppose was actually just forgotten before. This causes the DAG combiner to do slightly more than it used to, which resulted in the X86 backend blowing up because it got a slightly surprising node it wasn't expecting, so I tweaked it. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52254 91177308-0d34-0410-b5e6-96231b3b80d8
* XFAIL some tests that became failing due to the extra error reporting ↵Matthijs Kooijman2008-06-137-0/+15
| | | | | | recently. PR's are created for these. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52250 91177308-0d34-0410-b5e6-96231b3b80d8
* Crash less. The i64 restriction in BinomialCoefficient caused some problemsNick Lewycky2008-06-131-0/+43
| | | | | | | | | with code that was expecting different bit widths for different values. Make getTruncateOrZeroExtend a method on ScalarEvolution, and use it. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52248 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix some tests.Evan Cheng2008-06-125-9/+8
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52245 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert 52223.Evan Cheng2008-06-121-2/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52243 91177308-0d34-0410-b5e6-96231b3b80d8
* Don't try to compile tests for the ev56 alpha subtarget, which hasn't beenMatthijs Kooijman2008-06-122-3/+0
| | | | | | | supported since r33492. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52237 91177308-0d34-0410-b5e6-96231b3b80d8
* Pass -silence-passes to bugpoint in testcases, this makes two out of three ↵Matthijs Kooijman2008-06-123-3/+3
| | | | | | bugpoint testcases work again. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52236 91177308-0d34-0410-b5e6-96231b3b80d8
* Add line continuation character so the avoid dup loop header test actually runs.Matthijs Kooijman2008-06-121-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52228 91177308-0d34-0410-b5e6-96231b3b80d8
* Avoid duplicating loop header which leads to unnatural loops (and just seem ↵Evan Cheng2008-06-111-0/+27
| | | | | | | | | like general badness to me, likely to cause code explosion). Patch by Florian Brandner. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52223 91177308-0d34-0410-b5e6-96231b3b80d8
* Don't send checkpoints to stderr for the vmcore.ml test.Gordon Henriksen2008-06-111-6/+20
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52218 91177308-0d34-0410-b5e6-96231b3b80d8
* Teach instruction combining about the extractvalue. It can succesfully foldMatthijs Kooijman2008-06-111-0/+24
| | | | | | | | | useless insert-extract chains, similar to how it folds them for vectors. Add a testcase for this. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52217 91177308-0d34-0410-b5e6-96231b3b80d8
* Use %link not %llvmgxx (which includes -c) to do the link.Dale Johannesen2008-06-101-1/+1
| | | | | | | | | The test still fails because an expected symbol is not present, and I don't see why it should be. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52188 91177308-0d34-0410-b5e6-96231b3b80d8
* Suppress ObjC FE warnings, which cause the test to fail.Dale Johannesen2008-06-101-1/+1
| | | | | | | | Warnings are legitimate. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52187 91177308-0d34-0410-b5e6-96231b3b80d8
* Add -w to inhibit gcc warnings, which causes theDale Johannesen2008-06-108-8/+8
| | | | | | | | | harness to fail the tests. The warning all appear legitimate. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52186 91177308-0d34-0410-b5e6-96231b3b80d8