summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/CellSPU/SPUISelLowering.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Add more plumbing. This time in the LowerArguments and "get" functions whichBill Wendling2009-12-221-2/+2
| | | | | | | | return partial registers. This affected the back-end lowering code some. Also patch up some places I missed before in the "get" functions. llvm-svn: 91880
* Remove ISD::DEBUG_LOC and ISD::DBG_LABEL, which are no longer used.Dan Gohman2009-11-231-3/+0
| | | | | | | | Note that "hasDotLocAndDotFile"-style debug info was already broken; people wanting this functionality should implement it in the AsmPrinter/DwarfWriter code. llvm-svn: 89711
* We are not using DBG_STOPPOINT anymore.Devang Patel2009-11-211-1/+0
| | | | llvm-svn: 89536
* Add a bool flag to StackObjects telling whether they reference spillDavid Greene2009-11-121-2/+3
| | | | | | | | | | | | | slots. The AsmPrinter will use this information to determine whether to print a spill/reload comment. Remove default argument values. It's too easy to pass a wrong argument value when multiple arguments have default values. Make everything explicit to trap bugs early. Update all targets to adhere to the new interfaces.. llvm-svn: 87022
* Remove strange 'const' qualifiers, as warned about by iccDuncan Sands2009-09-061-2/+2
| | | | | | (#411). Patch by Erick Tryzelaar. llvm-svn: 81113
* Retype from unsigned to CallingConv::ID accordingly. Approved by Bob Wilson.Sandeep Patel2009-09-021-3/+3
| | | | llvm-svn: 80773
* Updated i128 sext support for CellSPU backend, contributed by Ken Werner (IBM)Scott Michel2009-08-251-16/+32
| | | | llvm-svn: 80042
* 128-bit sign extension and vector shift cleanups, contributed by Ken WernerScott Michel2009-08-241-9/+45
| | | | | | (IBM). llvm-svn: 79949
* Initialize ShufBytes, as gcc 4.4 can't detect that the entire array isScott Michel2009-08-241-1/+3
| | | | | | | initialized and a warning about a potentially unintialized variable is generated. llvm-svn: 79946
* eliminate uses of cerr()Chris Lattner2009-08-231-22/+22
| | | | llvm-svn: 79834
* Allow targets to specify their choice of calling conventions perAnton Korobeynikov2009-08-141-1/+1
| | | | | | | | | | libcall. Take advantage of this in the ARM backend to rectify broken choice of CC when hard float is in effect. PIC16 may want to see if it could be of use in MakePIC16Libcall, which works unchanged. Patch by Sandeep! llvm-svn: 79033
* Add contexts to some of the MVT APIs. No functionality change yet, just the ↵Owen Anderson2009-08-121-7/+13
| | | | | | infrastructure work needed to get the contexts to where they need to be first. llvm-svn: 78759
* Split EVT into MVT and EVT, the former representing _just_ a primitive type, ↵Owen Anderson2009-08-111-458/+458
| | | | | | | | while the latter is capable of representing either a primitive or an extended type. llvm-svn: 78713
* Rename MVT to EVT, in preparation for splitting SimpleValueType out into its ↵Owen Anderson2009-08-101-514/+514
| | | | | | own struct type. llvm-svn: 78610
* SimpleValueType-ify a few more methods on TargetLowering.Owen Anderson2009-08-101-2/+2
| | | | llvm-svn: 78595
* Continue the SimpleValueType-ification.Owen Anderson2009-08-101-4/+4
| | | | llvm-svn: 78593
* Start moving TargetLowering away from using full MVTs and towards ↵Owen Anderson2009-08-101-2/+4
| | | | | | SimpleValueType, which will simplify the privatization of IntegerType in the future. llvm-svn: 78584
* Fix a bunch of namespace pollution.Dan Gohman2009-08-071-2/+2
| | | | llvm-svn: 78363
* Major calling convention code refactoring.Dan Gohman2009-08-051-79/+61
| | | | | | | | | | | | | | | | | | | Instead of awkwardly encoding calling-convention information with ISD::CALL, ISD::FORMAL_ARGUMENTS, ISD::RET, and ISD::ARG_FLAGS nodes, TargetLowering provides three virtual functions for targets to override: LowerFormalArguments, LowerCall, and LowerRet, which replace the custom lowering done on the special nodes. They provide the same information, but in a more immediately usable format. This also reworks much of the target-independent tail call logic. The decision of whether or not to perform a tail call is now cleanly split between target-independent portions, and the target dependent portion in IsEligibleForTailCallOptimization. This also synchronizes all in-tree targets, to help enable future refactoring and feature work. llvm-svn: 78142
* Move types back to the 2.5 API.Owen Anderson2009-07-291-3/+2
| | | | llvm-svn: 77516
* Rip all of the global variable lowering logic out of TargetAsmInfo. SinceChris Lattner2009-07-281-10/+8
| | | | | | | | | | | | | | | | | | | | it is highly specific to the object file that will be generated in the end, this introduces a new TargetLoweringObjectFile interface that is implemented for each of ELF/MachO/COFF/Alpha/PIC16 and XCore. Though still is still a brutal and ugly refactoring, this is a major step towards goodness. This patch also: 1. fixes a bunch of dangling pointer problems in the PIC16 backend. 2. disables the TargetLowering copy ctor which PIC16 was accidentally using. 3. gets us closer to xcore having its own crazy target section flags and pic16 not having to shadow sections with its own objects. 4. fixes wierdness where ELF targets would set CStringSection but not CStringSection_. Factor the code better. 5. fixes some bugs in string lowering on ELF targets. llvm-svn: 77294
* Get rid of the Pass+Context magic.Owen Anderson2009-07-221-1/+1
| | | | llvm-svn: 76702
* Add operation expansion/promotion for a bunch of operations, many of Eli Friedman2009-07-171-5/+54
| | | | | | which show up in test/CodeGen/Generic. llvm-svn: 76158
* llvm_unreachable->llvm_unreachable(0), LLVM_UNREACHABLE->llvm_unreachable.Torok Edwin2009-07-141-13/+13
| | | | | | | | | This adds location info for all llvm_unreachable calls (which is a macro now) in !NDEBUG builds. In NDEBUG builds location info and the message is off (it only prints "UREACHABLE executed"). llvm-svn: 75640
* eliminate extra space.Torok Edwin2009-07-141-6/+5
| | | | llvm-svn: 75630
* assert(0) -> LLVM_UNREACHABLE.Torok Edwin2009-07-111-12/+12
| | | | | | | | | Make llvm_unreachable take an optional string, thus moving the cerr<< out of line. LLVM_UNREACHABLE is now a simple wrapper that makes the message go away for NDEBUG builds. llvm-svn: 75379
* Thread LLVMContext through MVT and related parts of SDISel.Owen Anderson2009-07-091-3/+4
| | | | llvm-svn: 75153
* Implement changes from Chris's feedback.Torok Edwin2009-07-081-32/+45
| | | | | | Finish converting lib/Target. llvm-svn: 75043
* Add NumFixedArgs attribute to CallSDNode which indicates the number of fixed ↵Tilmann Scheller2009-07-031-1/+1
| | | | | | | | | | | arguments in a vararg call. With the SVR4 ABI on PowerPC, vector arguments for vararg calls are passed differently depending on whether they are a fixed or a variable argument. Variable vector arguments always go into memory, fixed vector arguments are put into vector registers. If there are no free vector registers available, fixed vector arguments are put on the stack. The NumFixedArgs attribute allows to decide for an argument in a vararg call whether it belongs to the fixed or variable portion of the parameter list. llvm-svn: 74764
* Update comments to make it clear that the function alignment is the Log2 of theBill Wendling2009-07-011-1/+1
| | | | | | bytes and not bytes. llvm-svn: 74624
* Add an "alignment" field to the MachineFunction object. It makes more sense toBill Wendling2009-06-301-0/+5
| | | | | | | | | | have the alignment be calculated up front, and have the back-ends obey whatever alignment is decided upon. This allows for future work that would allow for precise no-op placement and the like. llvm-svn: 74564
* Misc accumulated tweaks to legalization logic for various targets.Eli Friedman2009-06-161-0/+19
| | | | llvm-svn: 73476
* Don't abuse the quirky behavior of LegalizeDAG for XINT_TO_FP and Eli Friedman2009-05-271-2/+2
| | | | | | | | FP_TO_XINT. Necessary for some cleanups I'm working on. Updated from the previous version (r72431) to fix a bug and make some things a bit clearer. llvm-svn: 72445
* Back out r72431, it is causing a number of compilation crashes with clang.Daniel Dunbar2009-05-261-2/+2
| | | | llvm-svn: 72436
* Don't abuse the quirky behavior of LegalizeDAG for XINT_TO_FP andEli Friedman2009-05-261-2/+2
| | | | | | FP_TO_XINT. Necessary for some cleanups I'm working on. llvm-svn: 72431
* 2nd attempt, fixing SSE4.1 issues and implementing feedback from duncan.Nate Begeman2009-04-271-37/+32
| | | | | | | | | | | | | | PR2957 ISD::VECTOR_SHUFFLE now stores an array of integers representing the shuffle mask internal to the node, rather than taking a BUILD_VECTOR of ConstantSDNodes as the shuffle mask. A value of -1 represents UNDEF. In addition to eliminating the creation of illegal BUILD_VECTORS just to represent shuffle masks, we are better about canonicalizing the shuffle mask, resulting in substantially better code for some classes of shuffles. llvm-svn: 70225
* Revert 69952. Causes testsuite failures on linux x86-64.Rafael Espindola2009-04-241-29/+32
| | | | llvm-svn: 69967
* PR2957Nate Begeman2009-04-241-32/+29
| | | | | | | | | | | | | | ISD::VECTOR_SHUFFLE now stores an array of integers representing the shuffle mask internal to the node, rather than taking a BUILD_VECTOR of ConstantSDNodes as the shuffle mask. A value of -1 represents UNDEF. In addition to eliminating the creation of illegal BUILD_VECTORS just to represent shuffle masks, we are better about canonicalizing the shuffle mask, resulting in substantially better code for some classes of shuffles. A clean up of x86 shuffle code, and some canonicalizing in DAGCombiner is next. llvm-svn: 69952
* Use CHAR_BIT instead of hard-coding 8 in several places where itDan Gohman2009-04-011-1/+1
| | | | | | | is appropriate. This helps visually differentiate host-oriented calculations from target-oriented calculations. llvm-svn: 68227
* fix warning in -asserts mode.Chris Lattner2009-03-261-4/+3
| | | | llvm-svn: 67739
* CellSPU:Scott Michel2009-03-171-260/+118
| | | | | | | | | | | | - Fix fabs, fneg for f32 and f64. - Use BuildVectorSDNode.isConstantSplat, now that the functionality exists - Continue to improve i64 constant lowering. Lower certain special constants to the constant pool when they correspond to SPU's shufb instruction's special mask values. This avoids the overhead of performing a shuffle on a zero-filled vector just to get the special constant when the memory load suffices. llvm-svn: 67067
* CellSPU:Scott Michel2009-03-161-19/+15
| | | | | | | Incorporate Tilmann's 128-bit operation patch. Evidently, it gets the llvm-gcc bootstrap a bit further along. llvm-svn: 67048
* Revert BuildVectorSDNode related patches: 65426, 65427, and 65296.Evan Cheng2009-02-251-42/+44
| | | | llvm-svn: 65482
* Introduce the BuildVectorSDNode class that encapsulates the ISD::BUILD_VECTORScott Michel2009-02-221-44/+42
| | | | | | | | | 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
* Use getDebugLoc forwarder instead of getNode()->getDebugLoc.Dale Johannesen2009-02-071-2/+2
| | | | | | No functional change. llvm-svn: 64026
* Get rid of the last non-DebugLoc versions of getNode!Dale Johannesen2009-02-071-3/+3
| | | | | | | | | | | | 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 versions of getNode.Dale Johannesen2009-02-061-37/+49
| | | | llvm-svn: 63969
* Get rid of one more non-DebugLoc getNode andDale Johannesen2009-02-061-73/+82
| | | | | | | its corresponding getTargetNode. Lots of caller changes. llvm-svn: 63904
* Remove non-DebugLoc forms of CopyToReg and CopyFromReg.Dale Johannesen2009-02-041-35/+41
| | | | | | Adjust callers. llvm-svn: 63789
* Remove non-DebugLoc versions of getLoad and getStore.Dale Johannesen2009-02-041-42/+52
| | | | | | Adjust the many callers of those versions. llvm-svn: 63767
OpenPOWER on IntegriCloud