summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen
Commit message (Collapse)AuthorAgeFilesLines
...
* simplify: we have solid argument iterator rangeGabor Greif2010-06-281-7/+4
| | | | llvm-svn: 107014
* Revert r106907, "make sure to handle dbg_value instructions in the middle of theDaniel Dunbar2010-06-281-10/+2
| | | | | | block, not...", it caused a bunch of nightly test regressions. llvm-svn: 107009
* Remove dead code.Devang Patel2010-06-282-3/+1
| | | | llvm-svn: 106990
* When splitting a VAARG, remember its alignment.Rafael Espindola2010-06-263-8/+28
| | | | | | This produces terrible but correct code. llvm-svn: 106952
* Revert my if-conversion cleanup since it caused a bunch of nightly testBob Wilson2010-06-261-37/+33
| | | | | | | | | | regressions. --- Reverse-merging r106939 into '.': U test/CodeGen/Thumb2/thumb2-ifcvt3.ll U lib/CodeGen/IfConversion.cpp llvm-svn: 106951
* VNInfos don't need to be destructed anymore.Benjamin Kramer2010-06-262-4/+4
| | | | llvm-svn: 106943
* Clean up some problems with extra CFG edges being introduced duringBob Wilson2010-06-261-33/+37
| | | | | | | | | | | | | | | if-conversion. The RemoveExtraEdges function doesn't work for blocks that end with unanalyzable branches, so in those cases, the "extra" edges must be explicitly removed. The CopyAndPredicateBlock and MergeBlocks methods can also avoid copying successor edges due to branches that have already been removed. The latter case is especially helpful when MergeBlocks is called for handling "diamond" if-conversions, where otherwise you can end up with some weird intermediate states in the CFG. Unfortunately I've been unable to find cases where this cleanup actually makes a significant difference in the code. There is one test where we manage to remove an empty block at the end of a function. Radar 6911268. llvm-svn: 106939
* make sure to handle dbg_value instructions in the middle of the block, notJim Grosbach2010-06-251-2/+10
| | | | | | just at the head, when doing diamond if-conversion. rdar://7797940 llvm-svn: 106907
* Don't track kills in VNInfo. Use interval ends instead.Jakob Stoklund Olesen2010-06-256-191/+79
| | | | | | | | | | | | The VNInfo.kills vector was almost unused except for all the code keeping it updated. The few places using it were easily rewritten to check for interval ends instead. The two new methods LiveInterval::killedAt and killedInRange are replacements. This brings us down to 3 independent data structures tracking kills. llvm-svn: 106905
* Change if-conversion block size limit checks to add some flexibility.Evan Cheng2010-06-252-14/+18
| | | | llvm-svn: 106901
* Collect debug info for optimized variables of inlined functions.Devang Patel2010-06-252-6/+30
| | | | llvm-svn: 106895
* 80 column and typo fixJim Grosbach2010-06-251-2/+2
| | | | llvm-svn: 106894
* The hasMemory argument is irrelevant to how the argumentDale Johannesen2010-06-252-7/+5
| | | | | | | | | for an "i" constraint should get lowered; PR 6309. While this argument was passed around a lot, this is the only place it was used, so it goes away from a lot of other places. llvm-svn: 106893
* - Reapply r106066 now that the bzip2 build regression has been fixed.Bill Wendling2010-06-251-50/+10
| | | | | | - 2010-06-25-CoalescerSubRegDefDead.ll is the testcase for r106878. llvm-svn: 106880
* We should remove the live range from the destination register only if *all* defsBill Wendling2010-06-251-2/+2
| | | | | | | | | are dead, not just the def of this register. I.e., a register could be dead, but it's subreg isn't. Testcase to follow with a subsequent patch. llvm-svn: 106878
* Cosmetic.Dale Johannesen2010-06-251-5/+2
| | | | llvm-svn: 106865
* Remove variables which are assigned to but for which the valueDuncan Sands2010-06-254-11/+1
| | | | | | is not used. Spotted by gcc-4.6. llvm-svn: 106854
* use ArgOperand accessorsGabor Greif2010-06-251-9/+14
| | | | | | | | | | and CallInst for getting hold of the intrinsic's arguments simplify along the way (at least for me this is much more legible now) Bill, Baldrick or Anton, please review\! llvm-svn: 106838
* use ArgOperand API (the simple part)Gabor Greif2010-06-251-2/+2
| | | | llvm-svn: 106837
* use ArgOperand APIGabor Greif2010-06-251-140/+140
| | | | llvm-svn: 106836
* use ArgOperand APIGabor Greif2010-06-251-1/+1
| | | | llvm-svn: 106835
* use ArgOperand API and CallSite to access arguments of CallInstGabor Greif2010-06-251-23/+26
| | | | llvm-svn: 106833
* use ArgOperand API and CallSite to access arguments of CallInstGabor Greif2010-06-252-9/+11
| | | | llvm-svn: 106829
* use ArgOperand APIGabor Greif2010-06-251-1/+1
| | | | llvm-svn: 106828
* prune an includeGabor Greif2010-06-251-1/+0
| | | | llvm-svn: 106827
* Fix a case where an earlyclobber operand of an asmDale Johannesen2010-06-251-0/+17
| | | | | | | | is reused as an input. PR 4118. Testcase is too big, as usual with bugs in this area, but there's one in the PR. llvm-svn: 106816
* Make sure all eliminated kills are removed from VNInfo lists.Jakob Stoklund Olesen2010-06-241-0/+2
| | | | | | | | This fixes PR7479 and PR7485. The test cases from those PRs are big, so not included. However, PR7485 comes from self hosting on FreeBSD, so we will surely hear about any regression. llvm-svn: 106811
* Add some comments.Dan Gohman2010-06-241-0/+7
| | | | llvm-svn: 106809
* Teach EmitLiveInCopies to omit copies for unused virtual registers,Dan Gohman2010-06-241-14/+25
| | | | | | and to clean up unused incoming physregs from the live-in list. llvm-svn: 106805
* It's possible that a flag is added to the SDNode that points back to theBill Wendling2010-06-241-11/+19
| | | | | | | original SDNode. This is badness. Also, this function allows one SDNode to point multiple flags to another SDNode. Badness as well. llvm-svn: 106793
* DBG_VALUE machine instruction pointing to undefined register for a variable ↵Devang Patel2010-06-241-4/+1
| | | | | | | | justify a separate scope if the variable is inlined function's argument. Radar 8122864. llvm-svn: 106792
* Don't return a std::vector in the Spiller interface, but take a reference to aJakob Stoklund Olesen2010-06-243-33/+38
| | | | | | | | vector instead. This avoids needless copying and allocation. Add documentation. llvm-svn: 106788
* Remove the now unused LiveIntervals::getVNInfoSourceReg().Jakob Stoklund Olesen2010-06-241-31/+0
| | | | | | | This method was always a bit too simplistic for the real world. It didn't really deal with subregisters and such. llvm-svn: 106781
* Teach AdjustCopiesBackFrom to also use CoalescerPair to identify compatible ↵Jakob Stoklund Olesen2010-06-242-16/+13
| | | | | | copies. llvm-svn: 106780
* Remove the -fast-spill option.Jakob Stoklund Olesen2010-06-241-87/+0
| | | | | | | This code path has never really been used, and we are going to be handling spilling through the Spiller interface in the future. llvm-svn: 106777
* Loosen up the requirements in the Horrible Hack(tm) to include all selectorsBill Wendling2010-06-241-30/+10
| | | | | | | | which don't have a catch-all associated with them not just clean-ups. This fixes the SingleSource/Benchmarks/Shootout-C++/except.cpp testcase that broke because of my change r105902. llvm-svn: 106772
* Replace a big gob of old coalescer logic with the new CoalescerPair class.Jakob Stoklund Olesen2010-06-243-731/+219
| | | | | | | | | | CoalescerPair can determine if a copy can be coalesced, and which register gets merged away. The old logic in SimpleRegisterCoalescing had evolved into something a bit too convoluted. This second attempt fixes some crashes that only occurred Linux. llvm-svn: 106769
* Print the LSBs of a SlotIndex symbolically using letters referring to theJakob Stoklund Olesen2010-06-241-1/+3
| | | | | | | | | [L]oad, [u]se, [d]ef, or [S]tore slots. This makes it easier to see if two indices refer to the same instruction, avoiding mental mod 4 calculations. llvm-svn: 106766
* Simplify this code; switch lowering shouldn't produce casesDan Gohman2010-06-241-12/+4
| | | | | | which trivially fold away. llvm-svn: 106765
* Be more strict about subreg-to-subreg copies in CoalescerPair.Jakob Stoklund Olesen2010-06-241-5/+15
| | | | | | Also keep track of the original DstREg before subregister adjustments. llvm-svn: 106753
* Verify that VNI kills are pointing to existing instructions.Jakob Stoklund Olesen2010-06-241-0/+1
| | | | | | | In this case it is essential that the kill is real because the spiller will decide to omit a spill if it thinks there is a later kill. llvm-svn: 106751
* Eliminate the other half of the BRCOND optimization, and updateDan Gohman2010-06-241-7/+0
| | | | | | as many tests as possible. llvm-svn: 106749
* Eliminate the first have of the optimization which eliminates BRCONDDan Gohman2010-06-241-3/+1
| | | | | | | | | | | | | when the condition is constant. This optimization shouldn't be necessary, because codegen shouldn't be able to find dead control paths that the IR-level optimizer can't find. And it's undesirable, because it encourages bugpoint to leave "br i1 false" branches in its output. And it wasn't updating the CFG. I updated all the tests I could, but some tests are too reduced and I wasn't able to meaningfully preserve them. llvm-svn: 106748
* Reapply r106634, now that the bug it exposed is fixed.Dan Gohman2010-06-244-111/+50
| | | | llvm-svn: 106746
* Optimize the "bit test" code path for switch lowering in theDan Gohman2010-06-241-15/+27
| | | | | | case where the bit mask has exactly one bit. llvm-svn: 106716
* Revert "Replace a big gob of old coalescer logic with the new CoalescerPair ↵Jakob Stoklund Olesen2010-06-244-205/+544
| | | | | | | | class." Whiny buildbots. llvm-svn: 106710
* Replace a big gob of old coalescer logic with the new CoalescerPair class.Jakob Stoklund Olesen2010-06-244-544/+205
| | | | | | | | CoalescerPair can determine if a copy can be coalesced, and which register gets merged away. The old logic in SimpleRegisterCoalescing had evolved into something a bit too convoluted. llvm-svn: 106701
* MorphNodeTo doesn't preserve the memory operands. Because we're morphing a nodeBill Wendling2010-06-231-0/+21
| | | | | | | into the same node, but with different non-memory operands, we need to replace the memory operands after it's finished morphing. llvm-svn: 106643
* Revert r106263, "Fold the ShrinkDemandedOps pass into the regular ↵Daniel Dunbar2010-06-234-50/+111
| | | | | | DAGCombiner pass,"... it was causing both 'file' (with clang) and 176.gcc (with llvm-gcc) to be miscompiled. llvm-svn: 106634
* Some targets don't require the fencing MEMBARRIER instructions surroundingJim Grosbach2010-06-232-0/+56
| | | | | | | | atomic intrinsics, either because the use locking instructions for the atomics, or because they perform the locking directly. Add support in the DAG combiner to fold away the fences. llvm-svn: 106630
OpenPOWER on IntegriCloud