summaryrefslogtreecommitdiff
path: root/lib
Commit message (Collapse)AuthorAge
* Reorder these.Duncan Sands2009-01-07
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61873 91177308-0d34-0410-b5e6-96231b3b80d8
* Use a switch rather than a sequence of "isa" tests.Duncan Sands2009-01-07
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61872 91177308-0d34-0410-b5e6-96231b3b80d8
* The verifier checks that the aliasee is not null.Duncan Sands2009-01-07
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61870 91177308-0d34-0410-b5e6-96231b3b80d8
* Implement the first half of PR3290: if there is a store of an Chris Lattner2009-01-07
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | integer to a (transitive) bitcast the alloca and if that integer has the full size of the alloca, then it clobbers the whole thing. Handle this by extracting pieces out of the stored integer and filing them away in the SROA'd elements. This triggers fairly frequently because the CFE uses integers to pass small structs by value and the inliner exposes these. For example, in kimwitu++, I see a bunch of these with i64 stores to "%struct.std::pair<std::_Rb_tree_const_iterator<kc::impl_abstract_phylum*>,bool>" In 176.gcc I see a few i32 stores to "%struct..0anon". In the testcase, this is a difference between compiling test1 to: _test1: subl $12, %esp movl 20(%esp), %eax movl %eax, 4(%esp) movl 16(%esp), %eax movl %eax, (%esp) movl (%esp), %eax addl 4(%esp), %eax addl $12, %esp ret vs: _test1: movl 8(%esp), %eax addl 4(%esp), %eax ret The second half of this will be to handle loads of the same form. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61853 91177308-0d34-0410-b5e6-96231b3b80d8
* Factor a bunch of code out into a helper method.Chris Lattner2009-01-07
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61852 91177308-0d34-0410-b5e6-96231b3b80d8
* use continue to simplify code and reduce nesting, no functionalityChris Lattner2009-01-07
| | | | | | | change. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61851 91177308-0d34-0410-b5e6-96231b3b80d8
* Get TargetData once up front and cache as an ivar instead ofChris Lattner2009-01-07
| | | | | | | requerying it all over the place. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61850 91177308-0d34-0410-b5e6-96231b3b80d8
* Use the hasAllZeroIndices predicate to simplify some Chris Lattner2009-01-07
| | | | | | | code, no functionality change. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61849 91177308-0d34-0410-b5e6-96231b3b80d8
* The coalescer does not coalesce a virtual register to a physical register if ↵Evan Cheng2009-01-07
| | | | | | | | | | | | | | | any of the physical register's sub-register live intervals overlaps with the virtual register. This is overly conservative. It prevents a extract_subreg from being coalesced away: v1024 = EDI // not killed = = EDI One possible solution is for the coalescer to examine the sub-register live intervals in the same manner as the physical register. Another possibility is to examine defs and uses (when needed) of sub-registers. Both solutions are too expensive. For now, look for "short virtual intervals" and scan instructions to look for conflict instead. This is a small win on x86-64. e.g. It shaves 403.gcc by ~80 instructions. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61847 91177308-0d34-0410-b5e6-96231b3b80d8
* Add patterns to match conditional moves with loads foldedDan Gohman2009-01-07
| | | | | | | | into their left operand, rather than their right. Do this by commuting the operands and inverting the condition. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61842 91177308-0d34-0410-b5e6-96231b3b80d8
* Add load-folding table entries for cmovno too.Dan Gohman2009-01-07
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61841 91177308-0d34-0410-b5e6-96231b3b80d8
* Define instructions for cmovo and cmovno.Dan Gohman2009-01-07
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61836 91177308-0d34-0410-b5e6-96231b3b80d8
* X86_COND_C and X86_COND_NC are alternate mnemonics forDan Gohman2009-01-07
| | | | | | | X86_COND_B and X86_COND_AE, respectively. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61835 91177308-0d34-0410-b5e6-96231b3b80d8
* Improve support for type-generic vector intrinsics by teaching TableGen howBob Wilson2009-01-07
| | | | | | | | | to handle LLVMMatchType intrinsic parameters, and by adding new subclasses of LLVMMatchType to match vector types with integral elements that are either twice as wide or half as wide as the elements of the matched type. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61834 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert r42653 and forward-port the code that lets INC64_32r beDan Gohman2009-01-06
| | | | | | | | | | | | | converted to LEA64_32r in x86's convertToThreeAddress. This replaces code like this: movl %esi, %edi inc %edi with this: lea 1(%rsi), %edi which appears to be beneficial. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61830 91177308-0d34-0410-b5e6-96231b3b80d8
* CellSPU:Scott Michel2009-01-06
| | | | | | | | - Add preliminary support for v2i32; load/store generates the right code but there's a lot work to be done to make this vector type operational. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61829 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix a bug in ComputeLinearIndex computation handling multi-levelDan Gohman2009-01-06
| | | | | | | | | aggregate types. Don't increment the current index after reaching the end of a struct, as it will already be pointing at one-past-the end. This fixes PR3288. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61828 91177308-0d34-0410-b5e6-96231b3b80d8
* Set up DwarfDebug using DebugInfo API.Devang Patel2009-01-06
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61822 91177308-0d34-0410-b5e6-96231b3b80d8
* Forgot that this was needed for Linux. This should fix the builds.Bill Wendling2009-01-06
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61819 91177308-0d34-0410-b5e6-96231b3b80d8
* The phi construction algorithm used for interval reconstruction is ↵Owen Anderson2009-01-06
| | | | | | | | | | | | complicated by two address instructions. We need to keep track of things we've processed AS USES independetly of whether we've processed them as defs. This fixes all known miscompilations when reconstruction is turned on. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61802 91177308-0d34-0410-b5e6-96231b3b80d8
* CellSPU: Update the READMEScott Michel2009-01-06
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61785 91177308-0d34-0410-b5e6-96231b3b80d8
* CellSPU:Scott Michel2009-01-06
| | | | | | | | | | | | | - Fix bugs 3194, 3195: i128 load/stores produce correct code (although, we need to ensure that i128 is 16-byte aligned in real life), and 128 zero- extends are supported. - New td file: SPU128InstrInfo.td: this is where all new i128 support should be put in the future. - Continue to hammer on i64 operations and test cases; ensure that the only remaining problem will be i64 mul. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61784 91177308-0d34-0410-b5e6-96231b3b80d8
* Update these argument lists for the isNormalMemoryDan Gohman2009-01-06
| | | | | | | argument. This doesn't affect current functionality. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61779 91177308-0d34-0410-b5e6-96231b3b80d8
* Use a latency value of 0 for the artificial edges inserted byDan Gohman2009-01-06
| | | | | | | | | | | | | AddPseudoTwoAddrDeps. This lets the scheduling infrastructure avoid recalculating node heights. In very large testcases this was a major bottleneck. Thanks to Roman Levenstein for finding this! As a side effect, fold-pcmpeqd-0.ll is now scheduled better and it no longer requires spilling on x86-32. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61778 91177308-0d34-0410-b5e6-96231b3b80d8
* Change m_ConstantInt and m_SelectCst to take their constant integersChris Lattner2009-01-05
| | | | | | | | as template arguments instead of as instance variables, exposing more optimization opportunities to the compiler earlier. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61776 91177308-0d34-0410-b5e6-96231b3b80d8
* Construct subprogram DIEs using DebugInfo.Devang Patel2009-01-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61772 91177308-0d34-0410-b5e6-96231b3b80d8
* Construct global variable DIEs using DebugInfo.Devang Patel2009-01-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61771 91177308-0d34-0410-b5e6-96231b3b80d8
* Construct compile unit dies using DebugInfo.Devang Patel2009-01-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61768 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert r61415 and r61484. Duncan was correct that these weren't needed.Bill Wendling2009-01-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61765 91177308-0d34-0410-b5e6-96231b3b80d8
* Don't call setDepthDirty/setHeightDirty when adding an edgeDan Gohman2009-01-05
| | | | | | | with latency 0, since it doesn't affect the depth or height. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61762 91177308-0d34-0410-b5e6-96231b3b80d8
* Extract source location info from DebugInfo.Devang Patel2009-01-05
| | | | | | | Add methods to add source location info in a DIE. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61761 91177308-0d34-0410-b5e6-96231b3b80d8
* Add type DIEs using DebugInfo.Devang Patel2009-01-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61757 91177308-0d34-0410-b5e6-96231b3b80d8
* Teach the internalize pass to also internalizeDuncan Sands2009-01-05
| | | | | | | global aliases. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61754 91177308-0d34-0410-b5e6-96231b3b80d8
* When checking if an Argument escapes, check ifDuncan Sands2009-01-05
| | | | | | | | | the argument is marked nocapture - no need to analyze the argument if the answer is already known! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61753 91177308-0d34-0410-b5e6-96231b3b80d8
* Find loop back edges only after empty blocks are eliminated.Evan Cheng2009-01-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61752 91177308-0d34-0410-b5e6-96231b3b80d8
* Not having an aliasee is a theoretical possibility.Duncan Sands2009-01-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61745 91177308-0d34-0410-b5e6-96231b3b80d8
* Format more neatly.Duncan Sands2009-01-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61744 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove trailing spaces.Duncan Sands2009-01-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61743 91177308-0d34-0410-b5e6-96231b3b80d8
* Delete unused global aliases with internal linkage.Duncan Sands2009-01-05
| | | | | | | | | In fact this also deletes those with linkonce linkage, however this is currently dead because for the moment aliases aren't allowed to have this linkage type. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61742 91177308-0d34-0410-b5e6-96231b3b80d8
* Construct composite type DIE using DebugInfo.Devang Patel2009-01-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61741 91177308-0d34-0410-b5e6-96231b3b80d8
* Add classof() methods so that dwarf writer can decide what DIDescriptor is ↵Devang Patel2009-01-05
| | | | | | in its hand. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61740 91177308-0d34-0410-b5e6-96231b3b80d8
* TargetLowering.h #includes SelectionDAGNodes.h, so it doesn't need itsDan Gohman2009-01-05
| | | | | | | | own OpActionsCapacity magic number; it can just use ISD::BUILTIN_OP_END, as long as it takes care to round up when needed. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61733 91177308-0d34-0410-b5e6-96231b3b80d8
* s/ConstructType/ConstructTypeDIE/gDevang Patel2009-01-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61731 91177308-0d34-0410-b5e6-96231b3b80d8
* Construct stuct field DIEs.Devang Patel2009-01-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61729 91177308-0d34-0410-b5e6-96231b3b80d8
* fix wordoChris Lattner2009-01-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61728 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove redundant ValID::ValID:: scoping (doesn't compile on Windows).Steve Naroff2009-01-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61727 91177308-0d34-0410-b5e6-96231b3b80d8
* Construct enumerator DIE using DebugInfo.Devang Patel2009-01-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61726 91177308-0d34-0410-b5e6-96231b3b80d8
* Reject PR3281:accepted03.ll with:Chris Lattner2009-01-05
| | | | | | | | | | llvm-as: accepted03.ll:1:35: invalid unresolved type up reference declare void @r({ \7, opaque, \10 } %su) ^ git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61725 91177308-0d34-0410-b5e6-96231b3b80d8
* Construct array/vector type DIEs using DebugInfo.Devang Patel2009-01-05
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61724 91177308-0d34-0410-b5e6-96231b3b80d8
* Get rid of sentinel insertion in interval reconstruction. It just masked theOwen Anderson2009-01-05
| | | | | | | problem, rather than fixing it. The problem has now been fixed the right way. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61723 91177308-0d34-0410-b5e6-96231b3b80d8