summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Fix BuildVectorSDNode::isConstantSplat to handle one-element vectors.Bob Wilson2009-03-041-2/+2
| | | | | | | It is an error to call APInt::zext with a size that is equal to the value's current size, so use zextOrTrunc instead. llvm-svn: 66039
* Generalize BuildVectorSDNode::isConstantSplat to use APInts and handleBob Wilson2009-03-021-78/+49
| | | | | | | | arbitrary vector sizes. Add an optional MinSplatBits parameter to specify a minimum for the splat element size. Update the PPC target to use the revised interface. llvm-svn: 65899
* Combine PPC's GetConstantBuildVectorBits and isConstantSplat functions to a newBob Wilson2009-03-011-0/+91
| | | | | | method in a BuildVectorSDNode "pseudo-class". llvm-svn: 65747
* Revert BuildVectorSDNode related patches: 65426, 65427, and 65296.Evan Cheng2009-02-251-144/+12
| | | | llvm-svn: 65482
* Expand tabs to spaces (overlooked in previous commit)Scott Michel2009-02-251-12/+12
| | | | llvm-svn: 65427
* Remove all "cached" data from BuildVectorSDNode, preferring to retrieveScott Michel2009-02-251-13/+8
| | | | | | | | | results via reference parameters. This patch also appears to fix Evan's reported problem supplied as a reduced bugpoint test case. llvm-svn: 65426
* Fix a ValueTracking rule: RHS means operand 1, not 0. Add a simpleDan Gohman2009-02-241-1/+1
| | | | | | | ashr instcombine to help expose this code. And apply the fix to SelectionDAG's copy of this code too. llvm-svn: 65364
* Introduce the BuildVectorSDNode class that encapsulates the ISD::BUILD_VECTORScott Michel2009-02-221-8/+145
| | | | | | | | | instruction. The class also consolidates the code for detecting constant splats that's shared across PowerPC and the CellSPU backends (and might be useful for other backends.) Also introduces SelectionDAG::getBUID_VECTOR() for generating new BUILD_VECTOR nodes. llvm-svn: 65296
* Remove trailing whitespace to reduce later commit patch noise.Scott Michel2009-02-171-169/+169
| | | | | | | | (Note: Eventually, commits like this will be handled via a pre-commit hook that does this automagically, as well as expand tabs to spaces and look for 80-col violations.) llvm-svn: 64827
* Use getDebugLoc forwarder instead of getNode()->getDebugLoc.Dale Johannesen2009-02-071-1/+1
| | | | | | No functional change. llvm-svn: 64026
* Make SDNode constructors take a DebugLoc always.Dale Johannesen2009-02-071-36/+4
| | | | | | | | | Adjust derived classes to pass UnknownLoc where a DebugLoc does not make sense. Pick one of DebugLoc and non-DebugLoc variants to survive for all such classes. llvm-svn: 64000
* Remove now-unused constructors.Dale Johannesen2009-02-071-21/+0
| | | | llvm-svn: 63995
* Get rid of the last non-DebugLoc versions of getNode!Dale Johannesen2009-02-071-14/+1
| | | | | | | | | | | | Many targets build placeholder nodes for special operands, e.g. GlobalBaseReg on X86 and PPC for the PIC base. There's no sensible way to associate debug info with these. I've left them built with getNode calls with explicit DebugLoc::getUnknownLoc operands. I'm not too happy about this but don't see a good improvement; I considered adding a getPseudoOperand or something, but it seems to me that'll just make it harder to read. llvm-svn: 63992
* Remove more non-DebugLoc getNode variants. UseDale Johannesen2009-02-061-27/+16
| | | | | | | | getCALLSEQ_{END,START} to permit passing no DebugLoc there. UNDEF doesn't logically have DebugLoc; add getUNDEF to encapsulate this. llvm-svn: 63978
* Remove more non-DebugLoc versions of getNode.Dale Johannesen2009-02-061-22/+0
| | | | llvm-svn: 63969
* Eliminate remaining non-DebugLoc version of getTargetNode.Dale Johannesen2009-02-061-39/+0
| | | | llvm-svn: 63951
* get rid of some non-DebugLoc getTargetNode variants.Dale Johannesen2009-02-061-41/+0
| | | | llvm-svn: 63909
* Get rid of one more non-DebugLoc getNode andDale Johannesen2009-02-061-11/+5
| | | | | | | its corresponding getTargetNode. Lots of caller changes. llvm-svn: 63904
* Remove a non-DebugLoc version of getNode.Dale Johannesen2009-02-051-6/+0
| | | | llvm-svn: 63889
* Remove 3 non-DebugLoc variants of getNode.Dale Johannesen2009-02-051-14/+0
| | | | llvm-svn: 63886
* Fix a bug where we were not emitting a cvt rnd sat node for convertingMon P Wang2009-02-051-2/+4
| | | | | | between a unsigned integer and signed integer. llvm-svn: 63831
* Get rid of 3 non-DebugLoc getNode variants.Dale Johannesen2009-02-051-17/+0
| | | | llvm-svn: 63808
* Remove non-DebugLoc versions of getMergeValues, ZeroExtendInReg.Dale Johannesen2009-02-051-20/+0
| | | | llvm-svn: 63800
* Remove non-DebugLoc forms of CopyToReg and CopyFromReg.Dale Johannesen2009-02-041-1/+1
| | | | | | Adjust callers. llvm-svn: 63789
* 80 column rule.Stuart Hastings2009-02-041-1/+2
| | | | llvm-svn: 63768
* Remove non-DebugLoc versions of getLoad and getStore.Dale Johannesen2009-02-041-85/+0
| | | | | | Adjust the many callers of those versions. llvm-svn: 63767
* Since I'm obliged to work with a development OS that currently doesn'tStuart Hastings2009-02-041-9/+56
| | | | | | | | | | support GraphViz, I've been using the foo->dump() facility. This patch is a minor rewrite to the SelectionDAG dump() stuff to make it a little more helpful. The existing foo->dump() functionality does not change; this patch adds foo->dumpr(). All of this is only useful when running LLVM under a debugger. llvm-svn: 63736
* Remove non-DebugLoc forms of the exotic formsDale Johannesen2009-02-041-82/+0
| | | | | | of Lod and Sto; patch uses. llvm-svn: 63716
* Remove some more non-DebugLoc versions of constructionDale Johannesen2009-02-041-40/+0
| | | | | | functions, with callers adjusted to fit. llvm-svn: 63705
* Remove a few non-DebugLoc versions of node creationDale Johannesen2009-02-041-138/+0
| | | | | | functions. llvm-svn: 63703
* DebugLoc propagation; adjustment to things omittedDale Johannesen2009-02-031-1/+22
| | | | | | from SelectionDagBuild. llvm-svn: 63680
* Add some DL propagation to places that didn'tDale Johannesen2009-02-031-36/+44
| | | | | | have it yet. More coming. llvm-svn: 63673
* First initialize DAG otherwise dwarf writer is used uninitialized.Devang Patel2009-02-031-1/+1
| | | | | | Duncan spotted this. Thanks! llvm-svn: 63641
* Fill in some missing DL propagation in getNode()s.Dale Johannesen2009-02-031-22/+24
| | | | llvm-svn: 63595
* Propagation in TargetLowering. Includes passing a DLDale Johannesen2009-02-031-11/+11
| | | | | | into SimplifySetCC which gets called elsewhere. llvm-svn: 63583
* Use the SubclassData field to hold ExtType, isTrunc, and MemIndexedModeDan Gohman2009-02-031-45/+40
| | | | | | | | information. This eliminates the need for the Flags field in MemSDNode, so this makes LoadSDNode and StoreSDNode smaller. Also, it makes FoldingSetNodeIDs for loads and stores two AddIntegers smaller. llvm-svn: 63577
* Commit missing files.Dale Johannesen2009-02-021-0/+14
| | | | llvm-svn: 63545
* Fix PR3453 and probably a bunch of other potentialDuncan Sands2009-02-011-3/+4
| | | | | | | | | crashes or wrong code with codegen of large integers: eliminate the legacy getIntegerVTBitMask and getIntegerVTSignBit methods, which returned their value as a uint64_t, so couldn't handle huge types. llvm-svn: 63494
* Fix PR3401: when using large integers, the typeDuncan Sands2009-01-311-3/+11
| | | | | | | | | | | | | returned by getShiftAmountTy may be too small to hold shift values (it is an i8 on x86-32). Before and during type legalization, use a large but legal type for shift amounts: getPointerTy; afterwards use getShiftAmountTy, fixing up any shift amounts with a big type during operation legalization. Thanks to Dan for writing the original patch (which I shamelessly pillaged). llvm-svn: 63482
* If unsafe FP optimization is not set, don't allow -(A-B) => B-A becauseMon P Wang2009-01-311-1/+2
| | | | | | when A==B, -0.0 != +0.0. llvm-svn: 63474
* Make LowerCallTo and LowerArguments take a DebugLocDale Johannesen2009-01-301-3/+6
| | | | | | argument. Adjust all callers and overloaded versions. llvm-svn: 63444
* Get rid of the non-DebugLoc-ified getNOT() method.Bill Wendling2009-01-301-15/+0
| | | | llvm-svn: 63442
* Propagate debug loc info for some of the *_EXTEND functions.Bill Wendling2009-01-301-0/+8
| | | | llvm-svn: 63434
* DebugLoc form of getNOT().Bill Wendling2009-01-301-0/+17
| | | | llvm-svn: 63433
* In the case of an extractelement on an insertelement value,Dan Gohman2009-01-291-1/+5
| | | | | | | the element indices may be equal if either one is not a constant. llvm-svn: 63311
* Revert r63273. This was already implemented by Dale. There's no need for myBill Wendling2009-01-291-72/+101
| | | | | | change. llvm-svn: 63301
* - Add DebugLoc to getTargetNode(). Bill Wendling2009-01-291-101/+72
| | | | | | | | | - Modify TableGen to add the DebugLoc when calling getTargetNode. (The light-weight wrappers are only temporary. The non-DebugLoc version will be removed once the whole debug info stuff is finished with.) llvm-svn: 63273
* Add DebugLoc-sensitive versions of many node creationDale Johannesen2009-01-291-0/+458
| | | | | | functions. Currently omitted: memcpy, memmove, memset. llvm-svn: 63259
* Add DebugLoc to the getNode() methods.Bill Wendling2009-01-281-41/+134
| | | | llvm-svn: 63245
* Add DebugLoc-aware constructors for SDNode derivedDale Johannesen2009-01-281-0/+23
| | | | | | | classes (those that reasonably have a DebugLoc associated with them). llvm-svn: 63236
OpenPOWER on IntegriCloud