summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/PowerPC
Commit message (Collapse)AuthorAgeFilesLines
...
* Fix PR4926. When target hook EmitInstrWithCustomInserter() insert new basic ↵Evan Cheng2009-09-191-2/+11
| | | | | | blocks and update CFG, it should also inform sdisel of the changes so the phi source operands will come from the right basic blocks. llvm-svn: 82311
* Enhance EmitInstrWithCustomInserter() so target can specify CFG changes that ↵Evan Cheng2009-09-182-2/+4
| | | | | | | | sdisel will use to properly complete phi nodes. Not functionality change yet. llvm-svn: 82273
* Model the carry bit on ppc32. Without this we couldDale Johannesen2009-09-183-28/+60
| | | | | | | move a SUBFC (etc.) below the SUBFE (etc.) that consumed the carry bit. Add missing ADDIC8, noticed along the way. llvm-svn: 82266
* Big change #1 for personality function references:Chris Lattner2009-09-161-3/+0
| | | | | | | | | | | | | | | | | | | | | | | | Eliminate the PersonalityPrefix/Suffix & NeedsIndirectEncoding fields from MAI: they aren't part of the asm syntax, they are related to the structure of the object file. To replace their functionality, add a new TLOF::getSymbolForDwarfGlobalReference method which asks targets to decide how to reference a global from EH in a pc-relative way. The default implementation just returns the symbol. The default darwin implementation references the symbol through an indirect $non_lazy_ptr stub. The bizarro x86-64 darwin specialization handles the weird "foo@GOTPCREL+4" hack. DwarfException.cpp now uses this to emit the reference to the symbol in the right way, and this also eliminates another horrible hack from DwarfException.cpp: - if (strcmp(MAI->getPersonalitySuffix(), "+4@GOTPCREL")) - O << "-" << MAI->getPCSymbol(); llvm-svn: 81991
* eliminate the PPC backend's implementation of EmitExternalGlobalChris Lattner2009-09-162-15/+3
| | | | | | | | | | | | | | | | and use PersonalityPrefix/Suffix to achieve the same effect (like the x86 backend). This changes the code generated for ppc static mode, but guess what, we were generating this before: .byte 0x9B ; Personality (indirect pcrel sdata4) .long ___gxx_personality_v0-. ; Personality which is not correct! (it is not an 'indirect' reference). llvm-svn: 81965
* remove all but one reference to TargetRegisterDesc::AsmName.Chris Lattner2009-09-131-1/+1
| | | | llvm-svn: 81714
* the tblgen produced 'getRegisterName' method does not accessChris Lattner2009-09-131-1/+1
| | | | | | the object, make it static instead of const. llvm-svn: 81711
* make tblgen produce a function that returns the name for a physreg.Chris Lattner2009-09-131-0/+2
| | | | | | Nothing is using this info yet. llvm-svn: 81707
* replace printBasicBlockLabel with EmitBasicBlockStart,Chris Lattner2009-09-131-2/+2
| | | | | | | now that printBasicBlockLabel is only used for starting a MBB. This allows elimination of a bunch of arguments. llvm-svn: 81684
* convert some uses of printBasicBlockLabel to use GetMBBSymbolChris Lattner2009-09-131-2/+3
| | | | | | instead. llvm-svn: 81677
* remove DebugLoc from MCInst and eliminate "Comment printing" fromChris Lattner2009-09-091-0/+4
| | | | | | | | | | | | | the MCInst path of the asmprinter. Instead, pull comment printing out of the autogenerated asmprinter into each target that uses the autogenerated asmprinter. This causes code duplication into each target, but in a way that will be easier to clean up later when more asmprinter stuff is commonized into the base AsmPrinter class. This also fixes an xcore strangeness where it inserted two tabs before every instruction. llvm-svn: 81396
* hoist the call to processDebugLoc out of the generatedChris Lattner2009-09-091-0/+2
| | | | | | | | | | | | | asm printer into the "printInstruction" routine. This fixes a problem where the experimental asmprinter would drop debug labels in some cases, and fixes issues on ppc/xcore where pseudo instructions like "mr" didn't get debug locs properly. It is annoying that this moves the call from one place into each target, but a future set of more invasive refactorings will fix that problem. llvm-svn: 81377
* Remove some not-really-used variables, as warnedDuncan Sands2009-09-061-3/+0
| | | | | | about by icc (#593, partial). Patch by Erick Tryzelaar. llvm-svn: 81115
* Retype from unsigned to CallingConv::ID accordingly. Approved by Bob Wilson.Sandeep Patel2009-09-022-22/+22
| | | | llvm-svn: 80773
* Revert commit 80428. It completely broke exceptionDuncan Sands2009-08-312-42/+0
| | | | | | handling on x86-32 linux. llvm-svn: 80592
* Normalize makefile comments and sort cmake file lists.Benjamin Kramer2009-08-312-2/+2
| | | | llvm-svn: 80584
* - Add target lowering methods to get the preferred format for the FDE and LSDABill Wendling2009-08-292-0/+42
| | | | | | | | | encodings. - Make some of the values emitted by the FDEs dependent upon the pointer size. This is in line with how GCC does things. And it has the benefit of working for Darwin in 64-bit mode now. llvm-svn: 80428
* Alter 79292 to produce output that actually assembles.Dale Johannesen2009-08-261-0/+2
| | | | llvm-svn: 80119
* Make linkerprivate work for ARM and PPC. Testcase coversDale Johannesen2009-08-241-4/+4
| | | | | | | | | all Darwin targets; could be split into separate tests for the chip subdirectories, but from Chris' last mail on testing I assume he'd rather have only one test. Generic seems to be the best available, maybe there should be a Darwin subdirectory? llvm-svn: 79877
* eliminate the last DOUTs from the targets.Chris Lattner2009-08-231-1/+2
| | | | llvm-svn: 79833
* Change Pass::print to take a raw ostream instead of std::ostream,Chris Lattner2009-08-231-1/+1
| | | | | | update all code that this affects. llvm-svn: 79830
* remove various std::ostream version of printing methods fromChris Lattner2009-08-231-3/+2
| | | | | | | | MachineInstr and MachineOperand. This required eliminating a bunch of stuff that was using DOUT, I hope that bill doesn't mind me stealing his fun. ;-) llvm-svn: 79813
* Forgot to update some CMakeLists.Benjamin Kramer2009-08-221-1/+1
| | | | llvm-svn: 79780
* rename TAI -> MAI, being careful not to make MAILJMP instructions :)Chris Lattner2009-08-221-13/+13
| | | | llvm-svn: 79777
* rename COFFMCAsmInfo -> MCAsmInfoCOFF, likewise for darwin.Chris Lattner2009-08-223-6/+6
| | | | llvm-svn: 79773
* Rename TargetAsmInfo (and its subclasses) to MCAsmInfo.Chris Lattner2009-08-225-26/+25
| | | | llvm-svn: 79763
* Record variable debug info at ISel time directly.Devang Patel2009-08-221-41/+0
| | | | llvm-svn: 79742
* eliminate AsmPrinter::SwitchToSection and just have clientsChris Lattner2009-08-191-21/+25
| | | | | | talk to the MCStreamer directly instead. llvm-svn: 79405
* Simplify RegScavenger::FindUnusedReg.Jakob Stoklund Olesen2009-08-181-1/+1
| | | | | | | | | - Drop the Candidates argument and fix all callers. Now that RegScavenger tracks available registers accurately, there is no need to restict the search. - Make sure that no aliases of the found register are in use. This was a potential bug. llvm-svn: 79369
* PowerPC inline asm was emitting two output operandsDale Johannesen2009-08-182-26/+12
| | | | | | | | | for a single "m" constraint; this is wrong because the opcode of a load or store would have to change in parallel. This patch makes it always compute addresses into a register, which is correct but not as efficient as possible. 7144566. llvm-svn: 79292
* Add support for the PowerPC 64-bit SVR4 ABI.Tilmann Scheller2009-08-159-72/+361
| | | | | | | | | | | | | | | | | The Link Register is volatile when using the 32-bit SVR4 ABI. Make it possible to use the 64-bit SVR4 ABI. Add non-volatile registers for the 64-bit SVR4 ABI. Make sure r2 is a reserved register when using the 64-bit SVR4 ABI. Update PPCFrameInfo for the 64-bit SVR4 ABI. Add FIXME for 64-bit Darwin PPC. Insert NOP instruction after direct function calls. Emit official procedure descriptors. Create TOC entries for GlobalAddress references. Spill 64-bit non-volatile registers to the correct slots. Only custom lower VAARG when using the 32-bit SVR4 ABI. Use simple VASTART lowering for the 64-bit SVR4 ABI. llvm-svn: 79091
* Simplify a few more things, eliminating a few more dependencies onDan Gohman2009-08-151-1/+1
| | | | | | "the current basic block". llvm-svn: 79069
* TargetRegistry: Change AsmPrinter constructor to be typed as returning anDaniel Dunbar2009-08-131-4/+4
| | | | | | AsmPrinter instance (instead of just a FunctionPass) llvm-svn: 78962
* Remove HasCrazyBSS and add a flag in TAI to indicate that '.section' Bruno Cardoso Lopes2009-08-132-1/+4
| | | | | | must be emitted for PowerPC-Linux '.bss' section llvm-svn: 78958
* Push LLVMContexts through the IntegerType APIs.Owen Anderson2009-08-131-1/+2
| | | | llvm-svn: 78948
* TargetRegistry: Reorganize AsmPrinter construction so that clients pass in theDaniel Dunbar2009-08-131-5/+5
| | | | | | | | | TargetAsmInfo. This eliminates a dependency on TargetMachine.h from TargetRegistry.h, which technically was a layering violation. - Clients probably can only sensibly pass in the same TargetAsmInfo as the TargetMachine has, but there are only limited clients of this API. llvm-svn: 78928
* Revert 78892 and 78895, these break generating working executables onDaniel Dunbar2009-08-133-13/+11
| | | | | | | | | | | | | | | | | | | | | x86_64-apple-darwin10. --- Reverse-merging r78895 into '.': U test/CodeGen/PowerPC/2008-12-12-EH.ll U lib/Target/DarwinTargetAsmInfo.cpp --- Reverse-merging r78892 into '.': U include/llvm/Target/DarwinTargetAsmInfo.h U lib/Target/X86/X86TargetAsmInfo.cpp U lib/Target/X86/X86TargetAsmInfo.h U lib/Target/ARM/ARMTargetAsmInfo.h U lib/Target/ARM/ARMTargetMachine.cpp U lib/Target/ARM/ARMTargetAsmInfo.cpp U lib/Target/PowerPC/PPCTargetAsmInfo.cpp U lib/Target/PowerPC/PPCTargetAsmInfo.h U lib/Target/PowerPC/PPCTargetMachine.cpp G lib/Target/DarwinTargetAsmInfo.cpp llvm-svn: 78919
* fix a minor fixme. When building with SL and later tools, the ".eh" symbolsChris Lattner2009-08-133-11/+13
| | | | | | don't need to be exported from the .o files. llvm-svn: 78892
* Various AsmWriter output cleanups. Use WriteAsOperand instead ofDan Gohman2009-08-131-15/+5
| | | | | | PrintUnmangledNameSafely. llvm-svn: 78878
* Change TargetAsmInfo to be constructed via TargetRegistry from a Target+TripleChris Lattner2009-08-122-8/+13
| | | | | | | | pair instead of from a virtual method on TargetMachine. This cuts the final ties of TargetAsmInfo to TargetMachine, meaning that MC can now use TargetAsmInfo. llvm-svn: 78802
* Add contexts to some of the MVT APIs. No functionality change yet, just the ↵Owen Anderson2009-08-121-1/+1
| | | | | | infrastructure work needed to get the contexts to where they need to be first. llvm-svn: 78759
* fix CodeGen/PowerPC/2007-01-15-AsmDialect.ll, fallout from r78742Chris Lattner2009-08-111-2/+2
| | | | llvm-svn: 78747
* second half of commit.Chris Lattner2009-08-111-2/+2
| | | | llvm-svn: 78744
* pass "is64Bit" flag into PPC TAI ctors instead of a whole targetmachine.Chris Lattner2009-08-112-20/+7
| | | | llvm-svn: 78743
* eliminate asmflavor from subtarget, PPCTAI is the only clientChris Lattner2009-08-113-19/+4
| | | | | | and each callee knows that it returns. llvm-svn: 78742
* Change the asmprinter to print the comment character before theChris Lattner2009-08-111-4/+0
| | | | | | | | | | "inlineasmstart/end" strings so that the contents of the directive are separate from the comment character. This lets elf targets get #APP/#NOAPP for free even if they don't use "#" as the comment character. This also allows hoisting the darwin stuff up to the shared TAI class. llvm-svn: 78737
* factorize more darwin TAI stuff. Note that this givesChris Lattner2009-08-111-6/+0
| | | | | | darwin/arm support for .no_dead_strip llvm-svn: 78734
* factorize darwin ProtectedDirective and SetDirective.Chris Lattner2009-08-111-2/+2
| | | | llvm-svn: 78732
* all darwin targets have .space and .zerofill, pull up.Chris Lattner2009-08-111-1/+0
| | | | llvm-svn: 78730
* move LCOMMDirective = "\t.lcomm\t" up to DarwinTAI, eliminateChris Lattner2009-08-112-31/+29
| | | | | | template in PPC backend for TAI. llvm-svn: 78727
OpenPOWER on IntegriCloud