summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen
Commit message (Collapse)AuthorAgeFilesLines
* Do run ComputeLiveOutVRegInfo with -fast.Evan Cheng2008-07-011-1/+1
| | | | llvm-svn: 52975
* Do not use computationally expensive scheduling heuristics with -fast.Evan Cheng2008-07-013-50/+59
| | | | llvm-svn: 52971
* Apply Chris' suggestion.Evan Cheng2008-07-011-32/+36
| | | | llvm-svn: 52970
* Minimize duplicated code in AsmPrinter::printLabel.Dan Gohman2008-07-011-2/+1
| | | | llvm-svn: 52944
* Split ISD::LABEL into ISD::DBG_LABEL and ISD::EH_LABEL, eliminatingDan Gohman2008-07-019-45/+67
| | | | | | | | | | | | | | | | the need for a flavor operand, and add a new SDNode subclass, LabelSDNode, for use with them to eliminate the need for a label id operand. Change instruction selection to let these label nodes through unmodified instead of creating copies of them. Teach the MachineInstr emitter how to emit a MachineInstr directly from an ISD label node. This avoids the need for allocating SDNodes for the label id and flavor value, as well as SDNodes for each of the post-isel label, label id, and label flavor. llvm-svn: 52943
* Suppress compiler warning.Evan Cheng2008-06-301-1/+1
| | | | llvm-svn: 52934
* Don't run stack slot coloring if -fast.Evan Cheng2008-06-301-2/+4
| | | | llvm-svn: 52933
* Use a simpler but equivalent form of RecordSource.Dan Gohman2008-06-301-2/+1
| | | | llvm-svn: 52931
* Add timing report for various sub-passes under SelectionDAGISel.Evan Cheng2008-06-301-0/+26
| | | | llvm-svn: 52930
* std::ostream and std::string microoptimizations for asm printing.Dan Gohman2008-06-301-84/+84
| | | | llvm-svn: 52929
* Use reserve.Dan Gohman2008-06-301-0/+1
| | | | | | | | | | SelectionDAG::allnodes_size is linear, but that doesn't appear to outweigh the benefit of reducing heap traffic. If it does become a problem, we should teach SelectionDAG to keep a count of how many nodes are live, because there are several other places where that information would be useful as well. llvm-svn: 52926
* Rename ISD::LOCATION to ISD::DBG_STOPPOINT to better reflect itsDan Gohman2008-06-304-44/+47
| | | | | | | | | | | | | | | | | purpose, and give it a custom SDNode subclass so that it doesn't need to have line number, column number, filename string, and directory string, all existing as individual SDNodes to be the operands. This was the only user of ISD::STRING, StringSDNode, etc., so remove those and some associated code. This makes stop-points considerably easier to read in -view-legalize-dags output, and reduces overhead (creating new nodes and copying std::strings into them) on code containing debugging information. llvm-svn: 52924
* Split scheduling from instruction selection.Evan Cheng2008-06-301-3/+11
| | | | llvm-svn: 52923
* No need to align the stack if there are no stackDale Johannesen2008-06-301-1/+2
| | | | | | objects. Fixes a couple of tests on Linux. llvm-svn: 52921
* Remove unneeded include.Evan Cheng2008-06-301-1/+0
| | | | llvm-svn: 52920
* Replace some std::vectors that showed up in heap profiling withDan Gohman2008-06-301-10/+9
| | | | | | | | SmallVectors. Change the signature of TargetLowering::LowerArguments to avoid returning a vector by value, and update the two targets which still use this directly, Sparc and IA64, accordingly. llvm-svn: 52917
* Correct the allocation size for CCState's UsedRegs member, whichDan Gohman2008-06-301-1/+1
| | | | | | | | only needs one bit for each register. UsedRegs is a SmallVector sized at 16, so this eliminates a heap allocation/free for every call and return processed by Legalize on most targets. llvm-svn: 52915
* ExpungeNode is only needed for new nodes! ThisDuncan Sands2008-06-301-9/+12
| | | | | | | fixes CodeGen/PowerPC/2008-06-19-LegalizerCrash.ll when using the new LegalizeTypes infrastructure. llvm-svn: 52903
* Support for VAARG. As noted in a comment, this isDuncan Sands2008-06-302-0/+33
| | | | | | | wrong for types like x86 long double and i1, but no worse than what is done in LegalizeDAG. llvm-svn: 52898
* Support for promoting select_cc operands.Duncan Sands2008-06-302-3/+16
| | | | llvm-svn: 52895
* Revert the SelectionDAG optimization that makesDuncan Sands2008-06-303-40/+27
| | | | | | | | | | | | | | | | | | it impossible to create a MERGE_VALUES node with only one result: sometimes it is useful to be able to create a node with only one result out of one of the results of a node with more than one result, for example because the new node will eventually be used to replace a one-result node using ReplaceAllUsesWith, cf X86TargetLowering::ExpandFP_TO_SINT. On the other hand, most users of MERGE_VALUES don't need this and for them the optimization was valuable. So add a new utility method getMergeValues for creating MERGE_VALUES nodes which by default performs the optimization. Change almost everywhere to use getMergeValues (and tidy some stuff up at the same time). llvm-svn: 52893
* - Re-apply 52748 and friends with fix. GetConstantStringInfo() returns an ↵Evan Cheng2008-06-302-30/+38
| | | | | | | | empty string for ConstantAggregateZero case which surprises selectiondag. - Correctly handle memcpy from constant string which is zero-initialized. llvm-svn: 52891
* Implement split and scalarize for SELECT_CC, fixing PR2504Chris Lattner2008-06-301-0/+23
| | | | llvm-svn: 52887
* Revert (52748 and friends):Anton Korobeynikov2008-06-292-11/+14
| | | | | | | | | | | | Move GetConstantStringInfo to lib/Analysis. Remove string output routine from Constant. Update all callers. Change debug intrinsic api slightly to accomodate move of routine, these now return values instead of strings. This unbreaks llvm-gcc bootstrap. llvm-svn: 52884
* Really fix the bootstrap failure.Chris Lattner2008-06-281-9/+5
| | | | llvm-svn: 52854
* Add back the capability to include nul characters in strings with Chris Lattner2008-06-281-1/+1
| | | | | | | GetConstantStringInfo. This will hopefully restore llvm-gcc to happy bootstrap land. llvm-svn: 52851
* When folding a bitcast into a load or store, preserve the alignmentDan Gohman2008-06-281-2/+2
| | | | | | | information of the original load or store, which is checked to be at least as good, and possibly better. llvm-svn: 52849
* Looks like this condition is inverted.Evan Cheng2008-06-271-2/+2
| | | | llvm-svn: 52841
* Reduce number of times .size() is called on a vector. Rename some variables toBill Wendling2008-06-271-16/+22
| | | | | | match normal naming scheme. llvm-svn: 52820
* Use a SmallSet when we can to reduce memory allocations.Owen Anderson2008-06-271-1/+2
| | | | | | This speeds up a particular testcase from 0.0302s to 0.0222s in LiveVariables. llvm-svn: 52819
* simplify this check, GetConstantStringInfo validates that aChris Lattner2008-06-271-5/+3
| | | | | | global is constant already. No functionality change. llvm-svn: 52812
* Cruft left from patch revert...sorry. :-(Bill Wendling2008-06-271-3/+6
| | | | llvm-svn: 52808
* Reverting broken patch r52803.Bill Wendling2008-06-271-33/+20
| | | | llvm-svn: 52806
* Don't perform expensive queries checking for super and sub registers when we ↵Owen Anderson2008-06-271-1/+2
| | | | | | | | know that there aren't any. This speed up LiveVariables on instcombine at -O0 -g from 0.3855s to 0.3503s. Look for more improvements in this area soon! llvm-svn: 52804
* - Remove a use of std::vector.Bill Wendling2008-06-271-12/+24
| | | | | | | - Make sure that we're not recalculating the size of a vector that never changes. llvm-svn: 52803
* Refactor the DebugInfoDesc stuff out of the MachineModuleInfo file. Clean upBill Wendling2008-06-274-803/+632
| | | | | | some uses of std::vector, where it's return std::vector by value. Yuck! llvm-svn: 52800
* duncan points out that isOperationLegal includes a check forChris Lattner2008-06-261-2/+2
| | | | | | type legality. Thanks Duncan! llvm-svn: 52786
* Don't create a whole new string just to copy the elements into it.Owen Anderson2008-06-261-5/+3
| | | | llvm-svn: 52785
* Fixes the last x86-64 test failure in compat.exp:Dale Johannesen2008-06-261-2/+6
| | | | | | | | | | | | | <16 x float> is 64-byte aligned (for some reason), which gets us into the stack realignment code. The computation changing FP-relative offsets to SP-relative was broken, assiging a spill temp to a location also used for parameter passing. This fixes it by rounding up the stack frame to a multiple of the largest alignment (I concluded it wasn't fixable without doing this, but I'm not very sure.) llvm-svn: 52750
* Move GetConstantStringInfo to lib/Analysis. RemoveEric Christopher2008-06-262-3/+8
| | | | | | | | | string output routine from Constant. Update all callers. Change debug intrinsic api slightly to accomodate move of routine, these now return values instead of strings. llvm-svn: 52748
* when we know the signbit of an input to uint_to_fp is zero,Chris Lattner2008-06-261-3/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | change it to sint_to_fp on targets where that is cheaper (and visaversa of course). This allows us to compile uint_to_fp to: _test: movl 4(%esp), %eax shrl $23, %eax cvtsi2ss %eax, %xmm0 movl 8(%esp), %eax movss %xmm0, (%eax) ret instead of: .align 3 LCPI1_0: ## double .long 0 ## double least significant word 4.5036e+15 .long 1127219200 ## double most significant word 4.5036e+15 .text .align 4,0x90 .globl _test _test: subl $12, %esp movl 16(%esp), %eax shrl $23, %eax movl %eax, (%esp) movl $1127219200, 4(%esp) movsd (%esp), %xmm0 subsd LCPI1_0, %xmm0 cvtsd2ss %xmm0, %xmm0 movl 20(%esp), %eax movss %xmm0, (%eax) addl $12, %esp ret llvm-svn: 52747
* Remember which MachineOperand we were processing, so we don't have to scan ↵Owen Anderson2008-06-251-11/+15
| | | | | | | | the list to find it again later. This speeds up live intervals from 0.37s to 0.30s on instcombine. llvm-svn: 52745
* Fix the text in an assert string.Dan Gohman2008-06-251-1/+1
| | | | llvm-svn: 52744
* - Fix a x86 vector isel bug: illegal transformation of a vector_shuffle into aEvan Cheng2008-06-251-11/+11
| | | | | | | | shift. - Add a readme entry for a missing vector_shuffle optimization that results in awful codegen. llvm-svn: 52740
* Add support for expanding PPC 128 bit floats.Duncan Sands2008-06-254-9/+215
| | | | | | | | | | | | | | | | | | | | For this it is convenient to permit floats to be used with EXTRACT_ELEMENT, so I tweaked things to allow that. I also added libcalls for ppcf128 to i32 forms of FP_TO_XINT, since they exist in libgcc and this case can certainly occur (and does occur in the testsuite) - before the i64 libcall was being used. Also, the XINT_TO_FP result seemed to be wrong when the argument is an i128: the wrong fudge factor was added (the i32 and i64 cases were handled directly, but the i128 code fell through to some generic softening code which seemed to think it was i64 to f32!). So I fixed it by adding a fudge factor that I found in my breakfast cereal. llvm-svn: 52739
* Add/complete support for integer and floatDuncan Sands2008-06-253-38/+282
| | | | | | | | select_cc and friends. This code could be factorized a bit but I'm not sure that it's worth it. llvm-svn: 52724
* Remove the OrigVT member from AtomicSDNode, as it is redundant withDan Gohman2008-06-253-13/+9
| | | | | | the base SDNode's VTList. llvm-svn: 52722
* Added MemOperands to Atomic operations since Atomics touches memory.Mon P Wang2008-06-253-34/+93
| | | | | | | | Added abstract class MemSDNode for any Node that have an associated MemOperand Changed atomic.lcs => atomic.cmp.swap, atomic.las => atomic.load.add, and atomic.lss => atomic.load.sub llvm-svn: 52706
* Enable two-address remat by default.Evan Cheng2008-06-251-35/+33
| | | | llvm-svn: 52701
* Use SmallVector instead of std::vector for a minor compile time improvement.Owen Anderson2008-06-241-11/+11
| | | | llvm-svn: 52689
OpenPOWER on IntegriCloud