summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen
Commit message (Collapse)AuthorAgeFilesLines
* Don't create ISD::FNEG nodes after legalize if they aren't legal.Dan Gohman2009-01-222-8/+30
| | | | | | | | | | | | | | Simplify x+0 to x in unsafe-fp-math mode. This avoids a bunch of redundant work in many cases, because in unsafe-fp-math mode, ISD::FADD with a constant is considered free to negate, so the DAGCombiner often negates x+0 to -0-x thinking it's free, when in reality the end result is -x, which is more expensive than x. Also, combine x*0 to 0. This fixes PR3374. llvm-svn: 62789
* Add SelectionDAG::getNOT method to construct bitwise NOT operations,Bob Wilson2009-01-224-26/+38
| | | | | | | corresponding to the "not" and "vnot" PatFrags. Use the new method in some places where it seems appropriate. llvm-svn: 62768
* Few targets like the tiny little PIC16 have only 16-bit pointers.Sanjiv Gupta2009-01-221-0/+4
| | | | llvm-svn: 62763
* Eliminate a couple of fields from TargetRegisterClass: SubRegClasses and ↵Evan Cheng2009-01-222-36/+5
| | | | | | SuperRegClasses. These are not necessary. Also eliminate getSubRegisterRegClass and getSuperRegisterRegClass. These are slow and their results can change if register file names change. Just use TargetLowering::getRegClassFor() to get the right TargetRegisterClass instead. llvm-svn: 62762
* fix a typoChris Lattner2009-01-221-1/+1
| | | | llvm-svn: 62761
* Simplify ReduceLoadWidth's logic: it doesn't need several differentDan Gohman2009-01-211-19/+10
| | | | | | | | special cases after producing the new reduced-width load, because the new load already has the needed adjustments built into it. This fixes several bugs due to the special cases, including PR3317. llvm-svn: 62692
* Cleanup whitespace and comments, and tweak someDuncan Sands2009-01-215-58/+53
| | | | | | | prototypes, in operand type legalization. No functionality change. llvm-svn: 62680
* I accidentally removed this check in an earlier commit, which cause breakage ↵Owen Anderson2009-01-211-0/+4
| | | | | | in the pre alloc splitter. llvm-svn: 62678
* CellSPU:Scott Michel2009-01-211-0/+4
| | | | | | | | | | | | | - Ensure that (operation) legalization emits proper FDIV libcall when needed. - Fix various bugs encountered during llvm-spu-gcc build, along with various cleanups. - Start supporting double precision comparisons for remaining libgcc2 build. Discovered interesting DAGCombiner feature, which is currently solved via custom lowering (64-bit constants are not legal on CellSPU, but DAGCombiner insists on inserting one anyway.) - Update README. llvm-svn: 62664
* Allow targets to legalize operations (with illegal operands) that produces ↵Sanjiv Gupta2009-01-215-68/+85
| | | | | | multiple values. For example, a load with an illegal operand (a load produces two values, a value and chain). llvm-svn: 62663
* Be more aggressive about renumbering vregs after splitting them.Owen Anderson2009-01-211-3/+7
| | | | llvm-svn: 62639
* Encode member accessibility.Devang Patel2009-01-211-1/+5
| | | | llvm-svn: 62638
* Appropriately mark fowrad decls.Devang Patel2009-01-201-11/+8
| | | | llvm-svn: 62625
* Fix PR3243: a LiveVariables bug. When HandlePhysRegKill is checking whether ↵Evan Cheng2009-01-201-13/+15
| | | | | | the last reference is also the last def (i.e. dead def), it should also check if last reference is the current machine instruction being processed. This can happen when it is processing a physical register use and setting the current machine instruction as sub-register's last ref. llvm-svn: 62617
* Use "SINT_TO_FP" instead of "UINT_TO_FP" when getting the exponent. This wasBill Wendling2009-01-201-12/+13
| | | | | | | causing the limited precision stuff to produce the wrong result for values in the range [0, 1). llvm-svn: 62615
* Fix struct member's debug info.Devang Patel2009-01-201-7/+24
| | | | llvm-svn: 62610
* Need only one set of debug info versions enum.Devang Patel2009-01-201-4/+4
| | | | llvm-svn: 62602
* Change TargetInstrInfo::isMoveInstr to return source and destination ↵Evan Cheng2009-01-209-57/+67
| | | | | | sub-register indices as well. llvm-svn: 62600
* Fix global variable's address in a DIE.Devang Patel2009-01-201-1/+1
| | | | llvm-svn: 62596
* Enable debug info for enums.Devang Patel2009-01-201-10/+14
| | | | llvm-svn: 62594
* Enable debug info for composite types.Devang Patel2009-01-201-4/+0
| | | | llvm-svn: 62589
* Refactor code. No functionality change.Evan Cheng2009-01-202-34/+89
| | | | llvm-svn: 62573
* Shift types need to match.Bill Wendling2009-01-201-8/+9
| | | | llvm-svn: 62571
* Fix a dagcombine to not generate loads of non-round integer types,Dan Gohman2009-01-201-1/+1
| | | | | | | as its comment says, even in the case where it will be generating extending loads. This fixes PR3216. llvm-svn: 62557
* Do not use DenseMap because the iterator is invalidated while constructing ↵Devang Patel2009-01-201-2/+2
| | | | | | types. After all there was a reason why std::map was used initially! llvm-svn: 62555
* Make linear scan's trivial coalescer slightly more aggressive.Evan Cheng2009-01-201-6/+6
| | | | llvm-svn: 62547
* Verify debug info.Devang Patel2009-01-193-10/+27
| | | | llvm-svn: 62545
* Remove SDNode's virtual destructor. This makes it impossible forDan Gohman2009-01-191-53/+14
| | | | | | | | | | | | | | SDNode subclasses to keep state that requires non-trivial destructors, however it was already effectively impossible, since the destructor isn't actually ever called. There currently aren't any SDNode subclasses affected by this, and in general it's desireable to keep SDNode objects light-weight. This eliminates the last virtual member function in the SDNode class, so it eliminates the need for a vtable pointer, making SDNode smaller. llvm-svn: 62539
* Fix SelectionDAG::ReplaceAllUsesWith to behave correctly whenDan Gohman2009-01-192-16/+39
| | | | | | | | | | | | | uses are added to the From node while it is processing From's use list, because of automatic local CSE. The fix is to avoid visiting any new uses. Fix a few places in the DAGCombiner that assumed that after a RAUW call, the From node has no users and may be deleted. This fixes PR3018. llvm-svn: 62533
* Few targets like PIC16 wants libcall generation for illegal type i16.Sanjiv Gupta2009-01-182-4/+16
| | | | llvm-svn: 62467
* Simplify extract element based on comments from Duncan Sands.Mon P Wang2009-01-181-7/+3
| | | | llvm-svn: 62459
* Remove tabs.Devang Patel2009-01-171-19/+19
| | | | llvm-svn: 62423
* Refactor codeDevang Patel2009-01-171-118/+73
| | | | llvm-svn: 62421
* Assign argument type to appropriate DIE.Devang Patel2009-01-171-2/+2
| | | | llvm-svn: 62412
* Remove dead code.Devang Patel2009-01-171-14/+2
| | | | llvm-svn: 62410
* Disable composite type debug info for now.Devang Patel2009-01-171-0/+3
| | | | llvm-svn: 62406
* Simplify extract element of a scalar to vector.Mon P Wang2009-01-171-5/+13
| | | | llvm-svn: 62383
* Instead of adding dependence edges between terminator instructionsDan Gohman2009-01-166-25/+65
| | | | | | | | | | | | | | and every other instruction in their blocks to keep the terminator instructions at the end, teach the post-RA scheduler how to operate on ranges of instructions, and exclude terminators from the range of instructions that get scheduled. Also, exclude mid-block labels, such as EH_LABEL instructions, and schedule code before them separately from code after them. This fixes problems with the post-RA scheduler moving code past EH_LABELs. llvm-svn: 62366
* If an anti-dependence uses a non-allocatable register, set AntiDepRegDan Gohman2009-01-161-1/+3
| | | | | | | to 0, to ensure that the subsequent code doesn't try to break the dependence. llvm-svn: 62365
* Use the getNode() accessor instead of accessing the NodeDan Gohman2009-01-161-1/+1
| | | | | | member directly, which is private as of r55504. llvm-svn: 62364
* Fix the check for an empty basic block to check for an empty SUnitsDan Gohman2009-01-161-2/+2
| | | | | | | | array instead, since this is what the scheduler actually cares about. And remove a check that is unnecessary, since it can assume that SUnits isn't empty. llvm-svn: 62362
* new nodes should be added to the worklist, not old nodes.Chris Lattner2009-01-161-1/+2
| | | | llvm-svn: 62359
* Fix comments.Devang Patel2009-01-161-5/+5
| | | | llvm-svn: 62358
* CreateVirtualRegisters does trivial copy coalescing. If a node def is used ↵Evan Cheng2009-01-162-56/+63
| | | | | | by a single CopyToReg, it reuses the virtual register assigned to the CopyToReg. This won't work for SDNode that is a clone or is itself cloned. Disable this optimization for those nodes or it can end up with non-SSA machine instructions. llvm-svn: 62356
* Use lightweight DebugInfo objects directly.Devang Patel2009-01-161-51/+50
| | | | llvm-svn: 62341
* Align source code.Devang Patel2009-01-161-4/+4
| | | | llvm-svn: 62328
* Fix a "comparison between signed and unsigned integer expressions"Dan Gohman2009-01-161-1/+1
| | | | | | warning. llvm-svn: 62327
* Registry.h should not depend on CommandLine.h.Mikhail Glushenkov2009-01-164-0/+4
| | | | | | | Split Support/Registry.h into two files so that we have less to recompile every time CommandLine.h is changed. llvm-svn: 62312
* Delete trailing whitespace.Mikhail Glushenkov2009-01-164-323/+323
| | | | llvm-svn: 62307
* Validate debug info values only if DwarfDebug is initialized.Devang Patel2009-01-161-1/+1
| | | | llvm-svn: 62298
OpenPOWER on IntegriCloud