summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/Alpha/AlphaISelLowering.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Retype from unsigned to CallingConv::ID accordingly. Approved by Bob Wilson.Sandeep Patel2009-09-021-4/+4
| | | | llvm-svn: 80773
* Split EVT into MVT and EVT, the former representing _just_ a primitive type, ↵Owen Anderson2009-08-111-161/+161
| | | | | | | | 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-166/+166
| | | | | | own struct type. llvm-svn: 78610
* Start moving TargetLowering away from using full MVTs and towards ↵Owen Anderson2009-08-101-1/+1
| | | | | | SimpleValueType, which will simplify the privatization of IntegerType in the future. llvm-svn: 78584
* avoid this libcall with long inline expansionAndrew Lenharth2009-08-071-1/+30
| | | | llvm-svn: 78420
* These should be expandedAndrew Lenharth2009-08-071-0/+3
| | | | llvm-svn: 78365
* Use elf Object File directlyAndrew Lenharth2009-08-051-18/+1
| | | | llvm-svn: 78220
* Alpha: Get section directives rightAndrew Lenharth2009-08-051-3/+3
| | | | llvm-svn: 78189
* Major calling convention code refactoring.Dan Gohman2009-08-051-82/+68
| | | | | | | | | | | | | | | | | | | 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
* Make SectionKind::get() private.Chris Lattner2009-08-021-3/+3
| | | | llvm-svn: 77835
* give alpha its readonly section. This optimizes alpha, and prevents aChris Lattner2009-08-011-0/+2
| | | | | | testsuite regression with a coming patch. llvm-svn: 77832
* Change SectionKind to be a property that is true of a *section*, itChris Lattner2009-08-011-2/+4
| | | | | | | | | | | | | | | | | | should have no state that is specific to particular globals in the section. In this case, it means the removal of the "isWeak" and "ExplicitSection" bits. MCSection uses the new form of SectionKind. To handle isWeak, I introduced a new SectionInfo class, which is SectionKind + isWeak, and it is used by the part of the code generator that does classification of a specific global. The ExplicitSection disappears. It is moved onto MCSection as a new "IsDirective" bit. Since the Name of a section is either a section or directive, it makes sense to keep this bit in MCSection. Ultimately the creator of MCSection should canonicalize (e.g.) .text to whatever the actual section is. llvm-svn: 77803
* switch off of 'Section' onto MCSection. We're not properly usingChris Lattner2009-07-311-2/+4
| | | | | | MCSection subclasses yet, but this is a step in the right direction. llvm-svn: 77708
* Rip all of the global variable lowering logic out of TargetAsmInfo. SinceChris Lattner2009-07-281-1/+14
| | | | | | | | | | | | | | | | | | | | 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-2/+2
| | | | llvm-svn: 76702
* Switch Alpha over to the new call lowering style. New code mostly Eli Friedman2009-07-191-80/+171
| | | | | | | | | | | | | copied from the SystemZ target. I don't think this causes any significant changes to the output (I compared the assembly, and the results appeared to be essentially unchanged), although I don't actually have an Alpha to test on. I would appreciate if anyone with the appropriate hardware could test this. I'm not sure if that includes anyone subscribed to llvm-commits, though. llvm-svn: 76353
* Set an operation expansion, noticed while running Eli Friedman2009-07-171-0/+2
| | | | | | llc over test/CodeGen/Generic with -march=alpha. llvm-svn: 76154
* llvm_unreachable->llvm_unreachable(0), LLVM_UNREACHABLE->llvm_unreachable.Torok Edwin2009-07-141-4/+4
| | | | | | | | | 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
* assert(0) -> LLVM_UNREACHABLE.Torok Edwin2009-07-111-3/+3
| | | | | | | | | 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
* Implement changes from Chris's feedback.Torok Edwin2009-07-081-0/+1
| | | | | | Finish converting lib/Target. llvm-svn: 75043
* Convert more abort() calls to llvm_report_error().Torok Edwin2009-07-081-2/+2
| | | | | | Also remove trailing semicolon. llvm-svn: 75027
* Add NumFixedArgs attribute to CallSDNode which indicates the number of fixed ↵Tilmann Scheller2009-07-031-1/+2
| | | | | | | | | | | 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
* Fix old-style type names in comments.Dan Gohman2009-06-141-1/+1
| | | | llvm-svn: 73362
* Convert Alpha and Mips to use a MachineFunctionInfo subclass toDan Gohman2009-06-031-3/+0
| | | | | | | | | | carry GlobalBaseReg, and GlobalRetAddr too in Alpha's case. This eliminates the need for them to search through the MachineRegisterInfo livein list in order to identify these virtual registers. EmitLiveInCopies is now the only user of the virtual register portion of MachineRegisterInfo's livein data. llvm-svn: 72802
* Remove non-DebugLoc versions of BuildMI from Alpha and Cell.Dale Johannesen2009-02-131-10/+11
| | | | llvm-svn: 64433
* Use getDebugLoc forwarder instead of getNode()->getDebugLoc.Dale Johannesen2009-02-071-1/+1
| | | | | | No functional change. llvm-svn: 64026
* Constify TargetInstrInfo::EmitInstrWithCustomInserter, allowingDan Gohman2009-02-071-1/+1
| | | | | | ScheduleDAG's TLI member to use const. llvm-svn: 64018
* Get rid of the last non-DebugLoc versions of getNode!Dale Johannesen2009-02-071-6/+8
| | | | | | | | | | | | 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-17/+22
| | | | llvm-svn: 63969
* Remove non-DebugLoc forms of CopyToReg and CopyFromReg.Dale Johannesen2009-02-041-5/+10
| | | | | | Adjust callers. llvm-svn: 63789
* Remove non-DebugLoc versions of getLoad and getStore.Dale Johannesen2009-02-041-11/+13
| | | | | | Adjust the many callers of those versions. llvm-svn: 63767
* Remove non-DebugLoc forms of the exotic formsDale Johannesen2009-02-041-11/+13
| | | | | | of Lod and Sto; patch uses. llvm-svn: 63716
* Remove some more non-DebugLoc versions of constructionDale Johannesen2009-02-041-9/+10
| | | | | | functions, with callers adjusted to fit. llvm-svn: 63705
* Make LowerCallTo and LowerArguments take a DebugLocDale Johannesen2009-01-301-7/+11
| | | | | | argument. Adjust all callers and overloaded versions. llvm-svn: 63444
* Add the private linkage.Rafael Espindola2009-01-151-1/+1
| | | | llvm-svn: 62279
* Fix PR3274: when promoting the condition of a BRCOND node,Duncan Sands2009-01-011-1/+1
| | | | | | | | | | promote from i1 all the way up to the canonical SetCC type. In order to discover an appropriate type to use, pass MVT::Other to getSetCCResultType. In order to be able to do this, change getSetCCResultType to take a type as an argument, not a value (this is also more logical). llvm-svn: 61542
* There are no longer any places that require aDuncan Sands2008-12-011-2/+2
| | | | | | | | MERGE_VALUES node with only one operand, so get rid of special code that only existed to handle that possibility. llvm-svn: 60349
* Change the interface to the type legalization methodDuncan Sands2008-12-011-3/+6
| | | | | | | | | | | ReplaceNodeResults: rather than returning a node which must have the same number of results as the original node (which means mucking around with MERGE_VALUES, and which is also easy to get wrong since SelectionDAG folding may mean you don't get the node you expect), return the results in a vector. llvm-svn: 60348
* Rename SetCCResultContents to BooleanContents. InDuncan Sands2008-11-231-1/+1
| | | | | | | practice these booleans are mostly produced by SetCC, however the concept is more general. llvm-svn: 59911
* fix another libgcc blockerAndrew Lenharth2008-11-111-0/+1
| | | | llvm-svn: 59026
* Teach DAGCombine to fold constant offsets into GlobalAddress nodes,Dan Gohman2008-10-181-0/+6
| | | | | | | | | | | | | | | | | | | | | | and add a TargetLowering hook for it to use to determine when this is legal (i.e. not in PIC mode, etc.) This allows instruction selection to emit folded constant offsets in more cases, such as the included testcase, eliminating the need for explicit arithmetic instructions. This eliminates the need for the C++ code in X86ISelDAGToDAG.cpp that attempted to achieve the same effect, but wasn't as effective. Also, fix handling of offsets in GlobalAddressSDNodes in several places, including changing GlobalAddressSDNode's offset from int to int64_t. The Mips, Alpha, Sparc, and CellSPU targets appear to be unaware of GlobalAddress offsets currently, so set the hook to false on those targets. llvm-svn: 57748
* Rename LoadX to LoadExt.Evan Cheng2008-10-141-7/+7
| | | | llvm-svn: 57526
* Change CALLSEQ_BEGIN and CALLSEQ_END to take TargetConstant's asChris Lattner2008-10-111-6/+3
| | | | | | | parameters instead of raw Constants. This prevents the constants from being selected by the isel pass, fixing PR2735. llvm-svn: 57385
* get CodeGen/Alpha/mul128.ll to work.Chris Lattner2008-10-091-0/+2
| | | | llvm-svn: 57318
* Note that ADDC and company don't actually expand yet (missing in legalizeAndrew Lenharth2008-10-071-1/+43
| | | | llvm-svn: 57226
* Add "inreg" field to CallSDNode (doesn't increaseDale Johannesen2008-09-261-3/+3
| | | | | | | | | its size). Adjust various lowering functions to pass this info through from CallInst. Use it to implement sseregparm returns on X86. Remove X86_ssecall calling convention. llvm-svn: 56677
* Make log, log2, log10, exp, exp2 use Expand byDale Johannesen2008-09-221-11/+0
| | | | | | default. llvm-svn: 56471
* Reverting r56249. On further investigation, this functionality isn't needed.Bill Wendling2008-09-161-8/+9
| | | | | | Apologies for the thrashing. llvm-svn: 56251
OpenPOWER on IntegriCloud