summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/X86/X86TargetAsmInfo.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Rename TargetAsmInfo (and its subclasses) to MCAsmInfo.Chris Lattner2009-08-221-131/+0
| | | | llvm-svn: 79763
* Revert 78892 and 78895, these break generating working executables onDaniel Dunbar2009-08-131-2/+4
| | | | | | | | | | | | | | | | | | | | | 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-131-4/+2
| | | | | | don't need to be exported from the .o files. llvm-svn: 78892
* Change TargetAsmInfo to be constructed via TargetRegistry from a Target+TripleChris Lattner2009-08-121-8/+8
| | | | | | | | 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
* prune #includage.Chris Lattner2009-08-111-12/+0
| | | | llvm-svn: 78748
* change the -x86-asm-syntax=intel/att flag to be in X86TAI Chris Lattner2009-08-111-6/+21
| | | | | | | instead of X86 Subtarget. This elimianates dependencies on X86Subtarget from X86TAI. llvm-svn: 78746
* Change the asmprinter to print the comment character before theChris Lattner2009-08-111-5/+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-1/+0
| | | | llvm-svn: 78732
* all darwin targets have .space and .zerofill, pull up.Chris Lattner2009-08-111-2/+0
| | | | llvm-svn: 78730
* move LCOMMDirective = "\t.lcomm\t" up to DarwinTAI, eliminateChris Lattner2009-08-111-2/+0
| | | | | | template in PPC backend for TAI. llvm-svn: 78727
* eliminate the X86TargetAsmInfo template.Chris Lattner2009-08-111-10/+18
| | | | llvm-svn: 78724
* SjLj based exception handling unwinding support. This patch is nasty, brutishJim Grosbach2009-08-111-2/+2
| | | | | | | | | | | | | and short. Well, it's kinda short. Definitely nasty and brutish. The front-end generates the register/unregister calls into the SjLj runtime, call-site indices and landing pad dispatch. The back end fills in the LSDA with the call-site information provided by the front end. Catch blocks are not yet implemented. Built on Darwin and verified no llvm-core "make check" regressions. llvm-svn: 78625
* remove the 'DataSectionStartSuffix' and 'TextSectionStartSuffix' knobs.Chris Lattner2009-08-051-4/+0
| | | | llvm-svn: 78242
* rip out SectionEndDirectiveSuffix support, only uses byChris Lattner2009-08-041-1/+0
| | | | | | | the masm backend. If anyone cares about masm in the future, we'll have semantic sections it can hang off of. llvm-svn: 78096
* move dwarf debug info section selection stuff from TAI toChris Lattner2009-08-021-12/+0
| | | | | | TLOF, unifying all the dwarf targets at the same time. llvm-svn: 77889
* convert EHFrameSection to be managed by TLOF instead of TAI.Chris Lattner2009-08-021-3/+0
| | | | llvm-svn: 77888
* remove TargetAsmInfo::TM, which is now dead. The basic TAI class now Chris Lattner2009-08-021-1/+1
| | | | | | no longer depends on TM! llvm-svn: 77863
* remove the x86/ppc impls of getEHGlobalPrefix, which is already dead.Chris Lattner2009-08-021-8/+0
| | | | llvm-svn: 77861
* remove the dead PreferredEHDataFormat TAI hook: its now deadChris Lattner2009-08-021-72/+0
| | | | | | even considering #if 0 code. llvm-svn: 77856
* move getDwarfExceptionSection from TAI to TLOF and rename it to Chris Lattner2009-08-021-2/+0
| | | | | | | | | | | getLSDASection() to be more specific. This makes it pretty obvious that the ELF LSDA section is being specified wrong in PIC mode. We're probably getting a lot of startup-time relocations to a readonly page, which is expensive and bad. Someone who cares about ELF C++ should investigate this. llvm-svn: 77847
* Remove "JumpTableDataSection" from TAI, instead, have AsmPrinterChris Lattner2009-08-011-1/+0
| | | | | | | | | | | | compute it based on what it knows. As part of this, rename getSectionForMergeableConstant to getSectionForConstant because it works for non-mergable constants also. The only functionality change from this is that Xcore will start dropping its jump tables into readonly section instead of data section in -static mode. This should be fine as the linker resolves the relocations. If this is a problem, let me know and we'll come up with another solution. llvm-svn: 77833
* REmove dead fields of TAI.Chris Lattner2009-08-011-5/+0
| | | | llvm-svn: 77820
* PreferredEHDataFormat is always call with data and global, but this wholeChris Lattner2009-07-311-38/+14
| | | | | | | thing is #if0'd out anyway. Just simplify the code by reducing the interface. Not deleting this is essential for Bill's continuing happiness. llvm-svn: 77736
* Change the "PreferredEHDataFormat" from "absptr" if we're on a Darwin system >Bill Wendling2009-07-291-5/+9
| | | | | | Leopard. llvm-svn: 77414
* Darwin outputs (DW_EH_PE_pcrel | DW_EH_PE_indirect | DW_EH_PE_sdata4) when we'reBill Wendling2009-07-281-2/+5
| | | | | | dealing with Data. llvm-svn: 77372
* Rip all of the global variable lowering logic out of TargetAsmInfo. SinceChris Lattner2009-07-281-5/+0
| | | | | | | | | | | | | | | | | | | | 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
* make COFF work like ELF and macho, by splitting out into its ownChris Lattner2009-07-271-59/+1
| | | | | | header even though there is only one COFF target. llvm-svn: 77204
* apparently we have "windows" and "coff", which are different(?)Chris Lattner2009-07-271-0/+3
| | | | llvm-svn: 77197
* 32-bit darwin targets support .literal16 too.Chris Lattner2009-07-271-4/+0
| | | | llvm-svn: 77191
* Eliminate getNamed/getUnnamedSection, adding a new and unified ↵Chris Lattner2009-07-271-13/+10
| | | | | | | | getOrCreateSection instead. llvm-svn: 77186
* Eliminate SectionFlags, just embed a SectionKind into SectionChris Lattner2009-07-271-9/+9
| | | | | | instead and drive things based off of that. llvm-svn: 77184
* untangle a TargetAsmInfo hack where ELFTargetAsmInfo would create aChris Lattner2009-07-261-0/+3
| | | | | | | | | 'unnamed' bss section, but some impls would want a named one. Since they don't have consistent behavior, just make each target do their own thing, instead of doing something "sortof common" then having targets change immutable objects later. llvm-svn: 77165
* remove a densemap from TargetAsmInfo that was uniquing the targetflags strings,Chris Lattner2009-07-261-10/+11
| | | | | | just use a smallstring instead. llvm-svn: 77144
* rename Mergable -> Mergeable and Writable -> WriteableChris Lattner2009-07-261-1/+1
| | | | llvm-svn: 77138
* Rearrange all the SectionKinds and structure them into a hierarchicalChris Lattner2009-07-261-1/+1
| | | | | | | | | | | | | group instead of a bunch of random unrelated ideas. Provide predicates to categorize a SectionKind into a group, and use them instead of getKind() throughout the code. This also renames a ton of SectionKinds to be more consistent and evocative, and adds a huge number of comments on the enums so that I will hopefully be able to remember how this stuff works long from now. llvm-svn: 77129
* make SectionKind be a first-class pod struct instead of justChris Lattner2009-07-251-16/+6
| | | | | | an enum. llvm-svn: 77096
* this is (unfortunately) several changes mixed together:Chris Lattner2009-07-251-3/+2
| | | | | | | | | | | | | | 1. Spell SectionFlags::Writeable as "Writable". 2. Add predicates for deriving SectionFlags from SectionKinds. 3. Sink ELF-specific getSectionPrefixForUniqueGlobal impl into ELFTargetAsmInfo. 4. Fix SectionFlagsForGlobal to know that BSS/ThreadBSS has the BSS bit set (the real fix for PR4619). 5. Fix isSuitableForBSS to not put globals with explicit sections set in BSS (which was the reason #4 wasn't fixed earlier). 6. Remove my previous hack for PR4619. llvm-svn: 77085
* make SectionKindForGlobal target independent, and therefore non-virtual.Chris Lattner2009-07-241-0/+4
| | | | | | | | It's classifications now include elf-specific discriminators. Targets that don't have these features (like darwin and pecoff) simply treat data.rel like data, etc. llvm-svn: 76993
* Switch to getNameStr().Daniel Dunbar2009-07-241-3/+3
| | | | llvm-svn: 76962
* Replace UniqueSectionForGlobal with getSectionPrefixForUniqueGlobal.Chris Lattner2009-07-241-24/+18
| | | | | | | | The later doesn't depend on any crazy LLVM IR stuff, and this pulls the concatenation of prefix with GV name (the root problem behind PR4584) out one level. llvm-svn: 76948
* remove TargetAsmInfo::ExpandInlineAsmChris Lattner2009-07-201-94/+0
| | | | llvm-svn: 76445
* Untangle a snarl that I discovered when updating the mangler,Chris Lattner2009-07-171-2/+1
| | | | | | | | | | | | | | starting in getCurrentFunctionEHName. Among other problems, we would try to privative a "foo.eh" label, but end up emitting the label as _Lfoo.eh instead of L_foo.eh on darwin. This is really bad, and the linker has always tolerated these labels existing. For now, just emit them as _foo.eh. This patch also fixes problems with ".eh" labels on unnamed functions and eliminates two strangely defined TargetAsmInfo hooks. llvm-svn: 76231
* llvm_unreachable->llvm_unreachable(0), LLVM_UNREACHABLE->llvm_unreachable.Torok Edwin2009-07-141-1/+1
| | | | | | | | | 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
* Reverted r75484. It was causing a failure with Apple-style builds.Bill Wendling2009-07-131-7/+1
| | | | llvm-svn: 75491
* More standard way of specifying greater than Leopard.Bill Wendling2009-07-131-3/+3
| | | | llvm-svn: 75488
* On greater than Leopard systems, place exception tables in the __TEXT section.Bill Wendling2009-07-131-3/+11
| | | | llvm-svn: 75484
* assert(0) -> LLVM_UNREACHABLE.Torok Edwin2009-07-111-1/+2
| | | | | | | | | 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
* Misc tweaks to Intel asm printing to make it more compatible with MASM. Eli Friedman2009-06-191-3/+8
| | | | | | Patch by Benedict Gaster. llvm-svn: 73753
* merge the common darwin settings from the X86/PPC/ARM targetsChris Lattner2009-06-191-43/+5
| | | | | | | | into DarwinTargetAsmInfo.cpp. The remaining differences should be evaluated. It seems strange that x86/arm has .zerofill but ppc doesn't, etc. llvm-svn: 73742
OpenPOWER on IntegriCloud