LLVM API Documentation
#include <TargetAsmInfo.h>


Definition at line 123 of file TargetAsmInfo.h.
| TargetAsmInfo::TargetAsmInfo | ( | ) |
Definition at line 122 of file TargetAsmInfo.cpp.
| TargetAsmInfo::TargetAsmInfo | ( | const TargetMachine & | TM | ) |
Definition at line 126 of file TargetAsmInfo.cpp.
| TargetAsmInfo::~TargetAsmInfo | ( | ) | [virtual] |
Definition at line 130 of file TargetAsmInfo.cpp.
| const Section * TargetAsmInfo::getNamedSection | ( | const char * | Name, | |
| unsigned | Flags = SectionFlags::None, |
|||
| bool | Override = false | |||
| ) | const |
Definition at line 347 of file TargetAsmInfo.cpp.
References llvm::Section::Flags, llvm::SectionFlags::Invalid, llvm::Section::Name, and llvm::SectionFlags::Named.
Referenced by llvm::DarwinTargetAsmInfo::DarwinTargetAsmInfo(), llvm::ELFTargetAsmInfo::ELFTargetAsmInfo(), llvm::ELFTargetAsmInfo::MergeableConstSection(), llvm::ELFTargetAsmInfo::MergeableStringSection(), llvm::MipsTargetAsmInfo::MipsTargetAsmInfo(), SectionForGlobal(), SelectSectionForGlobal(), llvm::ELFTargetAsmInfo::SelectSectionForGlobal(), and llvm::SparcELFTargetAsmInfo::SparcELFTargetAsmInfo().
| const Section * TargetAsmInfo::getUnnamedSection | ( | const char * | Directive, | |
| unsigned | Flags = SectionFlags::None, |
|||
| bool | Override = false | |||
| ) | const |
Definition at line 361 of file TargetAsmInfo.cpp.
References llvm::Section::Flags, llvm::SectionFlags::Invalid, llvm::Section::Name, and Named.
Referenced by llvm::DarwinTargetAsmInfo::DarwinTargetAsmInfo(), and llvm::ELFTargetAsmInfo::ELFTargetAsmInfo().
| unsigned TargetAsmInfo::getInlineAsmLength | ( | const char * | Str | ) | const [virtual] |
Measure the specified inline asm to determine an approximation of its length.
Measure the specified inline asm to determine an approximation of its length. Comments (which run till the next SeparatorChar or newline) do not count as an instruction. Any other non-whitespace text is considered an instruction, with multiple instructions separated by SeparatorChar or newlines. Variable-length instructions are not handled here; this function may be overloaded in the target code to do that.
Reimplemented in llvm::ARMTargetAsmInfo< llvm::DarwinTargetAsmInfo >, and llvm::ARMTargetAsmInfo< llvm::ELFTargetAsmInfo >.
Definition at line 141 of file TargetAsmInfo.cpp.
References CommentString, MaxInstLength, and SeparatorChar.
Referenced by llvm::PPCInstrInfo::GetInstSizeInBytes(), llvm::ARMInstrInfo::GetInstSizeInBytes(), and GetInstSizeWithDesc().
| virtual bool llvm::TargetAsmInfo::ExpandInlineAsm | ( | CallInst * | CI | ) | const [inline, virtual] |
ExpandInlineAsm - This hook allows the target to expand an inline asm call to be explicit llvm code if it wants to. This is useful for turning simple inline asms into LLVM intrinsics, which gives the compiler more information about the behavior of the code.
Reimplemented in llvm::X86TargetAsmInfo< llvm::DarwinTargetAsmInfo >, llvm::X86TargetAsmInfo< llvm::ELFTargetAsmInfo >, and llvm::X86TargetAsmInfo< llvm::TargetAsmInfo >.
Definition at line 532 of file TargetAsmInfo.h.
| virtual bool llvm::TargetAsmInfo::emitUsedDirectiveFor | ( | const GlobalValue * | GV, | |
| Mangler * | Mang | |||
| ) | const [inline, virtual] |
emitUsedDirectiveFor - This hook allows targets to selectively decide not to emit the UsedDirective for some symbols in llvm.used.
Reimplemented in llvm::DarwinTargetAsmInfo.
Definition at line 538 of file TargetAsmInfo.h.
| unsigned TargetAsmInfo::PreferredEHDataFormat | ( | DwarfEncoding::Target | Reason, | |
| bool | Global | |||
| ) | const [virtual] |
PreferredEHDataFormat - This hook allows the target to select data format used for encoding pointers in exception handling data. Reason is 0 for data, 1 for code labels, 2 for function pointers. Global is true if the symbol can be relocated.
Definition at line 159 of file TargetAsmInfo.cpp.
References llvm::dwarf::DW_EH_PE_absptr.
Referenced by llvm::PPCLinuxTargetAsmInfo::PreferredEHDataFormat().
| SectionKind::Kind TargetAsmInfo::SectionKindForGlobal | ( | const GlobalValue * | GV | ) | const [virtual] |
SectionKindForGlobal - This hook allows the target to select proper section kind used for global emission.
Reimplemented in llvm::MipsTargetAsmInfo.
Definition at line 174 of file TargetAsmInfo.cpp.
References llvm::SectionKind::BSS, llvm::CallingConv::C, llvm::Constant::ContainsRelocations(), llvm::SectionKind::Data, llvm::dyn_cast(), llvm::GlobalVariable::getInitializer(), llvm::GlobalVariable::isConstant(), llvm::ConstantArray::isCString(), isSuitableForBSS(), llvm::GlobalVariable::isThreadLocal(), llvm::SectionKind::ROData, llvm::SectionKind::RODataMergeConst, llvm::SectionKind::RODataMergeStr, llvm::SectionKind::Text, llvm::SectionKind::ThreadBSS, and llvm::SectionKind::ThreadData.
Referenced by SectionFlagsForGlobal(), llvm::MipsTargetAsmInfo::SectionKindForGlobal(), SelectSectionForGlobal(), llvm::ELFTargetAsmInfo::SelectSectionForGlobal(), and llvm::DarwinTargetAsmInfo::SelectSectionForGlobal().
| unsigned TargetAsmInfo::SectionFlagsForGlobal | ( | const GlobalValue * | GV = NULL, |
|
| const char * | name = NULL | |||
| ) | const [virtual] |
SectionFlagsForGlobal - This hook allows the target to select proper section flags either for given global or for section.
Reimplemented in llvm::MipsTargetAsmInfo.
Definition at line 208 of file TargetAsmInfo.cpp.
References llvm::SectionFlags::BSS, llvm::SectionKind::BSS, llvm::SectionFlags::Code, llvm::SectionKind::Data, Kind, llvm::SectionFlags::Linkonce, llvm::GlobalValue::mayBeOverridden(), llvm::SectionFlags::Named, llvm::SectionFlags::None, llvm::SectionKind::ROData, llvm::SectionKind::RODataMergeConst, llvm::SectionKind::RODataMergeStr, SectionKindForGlobal(), llvm::SectionFlags::Small, llvm::SectionKind::SmallBSS, llvm::SectionKind::SmallData, llvm::SectionKind::SmallROData, llvm::SectionKind::Text, llvm::SectionKind::ThreadBSS, llvm::SectionKind::ThreadData, llvm::SectionFlags::TLS, and llvm::SectionFlags::Writeable.
Referenced by llvm::AsmPrinter::EmitJumpTableInfo(), llvm::MipsTargetAsmInfo::SectionFlagsForGlobal(), SectionForGlobal(), SelectSectionForGlobal(), and llvm::ELFTargetAsmInfo::SelectSectionForGlobal().
| const Section * TargetAsmInfo::SectionForGlobal | ( | const GlobalValue * | GV | ) | const [virtual] |
SectionForGlobal - This hooks returns proper section name for given global with all necessary flags and marks.
Definition at line 273 of file TargetAsmInfo.cpp.
References getNamedSection(), llvm::GlobalValue::getSection(), llvm::GlobalValue::hasSection(), SectionFlagsForGlobal(), and SelectSectionForGlobal().
Referenced by llvm::X86ATTAsmPrinter::emitFunctionHeader(), llvm::AsmPrinter::EmitJumpTableInfo(), and llvm::X86ATTAsmPrinter::printModuleLevelGV().
| std::string TargetAsmInfo::UniqueSectionForGlobal | ( | const GlobalValue * | GV, | |
| SectionKind::Kind | kind | |||
| ) | const [virtual] |
Reimplemented in llvm::DarwinTargetAsmInfo.
Definition at line 318 of file TargetAsmInfo.cpp.
References llvm::SectionKind::BSS, llvm::SectionKind::Data, llvm::Value::getName(), llvm::SectionKind::ROData, llvm::SectionKind::RODataMergeConst, llvm::SectionKind::RODataMergeStr, llvm::SectionKind::SmallBSS, llvm::SectionKind::SmallData, llvm::SectionKind::SmallROData, llvm::SectionKind::Text, llvm::SectionKind::ThreadBSS, and llvm::SectionKind::ThreadData.
Referenced by SelectSectionForGlobal(), and llvm::ELFTargetAsmInfo::SelectSectionForGlobal().
| const std::string & TargetAsmInfo::getSectionFlags | ( | unsigned | Flags | ) | const |
Definition at line 375 of file TargetAsmInfo.cpp.
References llvm::DenseMap< KeyT, ValueT, KeyInfoT, ValueInfoT >::end(), llvm::DenseMap< KeyT, ValueT, KeyInfoT, ValueInfoT >::find(), I, llvm::DenseMap< KeyT, ValueT, KeyInfoT, ValueInfoT >::insert(), and printSectionFlags().
Referenced by llvm::AsmPrinter::SwitchToSection().
| virtual std::string llvm::TargetAsmInfo::printSectionFlags | ( | unsigned | flags | ) | const [inline, virtual] |
Reimplemented in llvm::ELFTargetAsmInfo, and llvm::SparcELFTargetAsmInfo.
Definition at line 571 of file TargetAsmInfo.h.
Referenced by getSectionFlags().
| const Section * TargetAsmInfo::SelectSectionForGlobal | ( | const GlobalValue * | GV | ) | const [virtual] |
Reimplemented in llvm::DarwinTargetAsmInfo, llvm::ELFTargetAsmInfo, and llvm::MipsTargetAsmInfo.
Definition at line 291 of file TargetAsmInfo.cpp.
References getBSSSection_(), getDataSection(), getNamedSection(), getReadOnlySection(), getTextSection(), llvm::SectionKind::isBSS(), llvm::SectionKind::isReadOnly(), Kind, llvm::GlobalValue::mayBeOverridden(), Name, SectionFlagsForGlobal(), SectionKindForGlobal(), llvm::SectionKind::Text, and UniqueSectionForGlobal().
Referenced by SectionForGlobal().
Reimplemented in llvm::DarwinTargetAsmInfo, and llvm::ELFTargetAsmInfo.
Definition at line 312 of file TargetAsmInfo.cpp.
References getDataSection().
Referenced by llvm::AsmPrinter::EmitConstantPool().
| unsigned TargetAsmInfo::getSLEB128Size | ( | int | Value | ) | [static] |
getSLEB128Size - Compute the number of bytes required for a signed leb128 value.
Definition at line 396 of file TargetAsmInfo.cpp.
getULEB128Size - Compute the number of bytes required for an unsigned leb128 value.
Definition at line 387 of file TargetAsmInfo.cpp.
| const Section* llvm::TargetAsmInfo::getTextSection | ( | ) | const [inline] |
Definition at line 589 of file TargetAsmInfo.h.
References TextSection.
Referenced by llvm::AsmPrinter::doFinalization(), and SelectSectionForGlobal().
| const Section* llvm::TargetAsmInfo::getDataSection | ( | ) | const [inline] |
Definition at line 592 of file TargetAsmInfo.h.
References DataSection.
Referenced by llvm::X86IntelAsmPrinter::doFinalization(), SelectSectionForGlobal(), and SelectSectionForMachineConst().
| const char* llvm::TargetAsmInfo::getBSSSection | ( | ) | const [inline] |
| const Section* llvm::TargetAsmInfo::getBSSSection_ | ( | ) | const [inline] |
Definition at line 598 of file TargetAsmInfo.h.
References BSSSection_.
Referenced by SelectSectionForGlobal(), and llvm::ELFTargetAsmInfo::SelectSectionForGlobal().
| const Section* llvm::TargetAsmInfo::getReadOnlySection | ( | ) | const [inline] |
Definition at line 601 of file TargetAsmInfo.h.
References ReadOnlySection.
Referenced by llvm::ELFTargetAsmInfo::MergeableConstSection(), llvm::DarwinTargetAsmInfo::MergeableConstSection(), llvm::ELFTargetAsmInfo::MergeableStringSection(), llvm::DarwinTargetAsmInfo::MergeableStringSection(), SelectSectionForGlobal(), llvm::ELFTargetAsmInfo::SelectSectionForGlobal(), llvm::DarwinTargetAsmInfo::SelectSectionForGlobal(), and llvm::DarwinTargetAsmInfo::SelectSectionForMachineConst().
| const Section* llvm::TargetAsmInfo::getSmallDataSection | ( | ) | const [inline] |
Definition at line 604 of file TargetAsmInfo.h.
References SmallDataSection.
Referenced by llvm::MipsTargetAsmInfo::SelectSectionForGlobal().
| const Section* llvm::TargetAsmInfo::getSmallBSSSection | ( | ) | const [inline] |
Definition at line 607 of file TargetAsmInfo.h.
References SmallBSSSection.
Referenced by llvm::MipsTargetAsmInfo::SelectSectionForGlobal().
| const Section* llvm::TargetAsmInfo::getSmallRODataSection | ( | ) | const [inline] |
| const Section* llvm::TargetAsmInfo::getTLSDataSection | ( | ) | const [inline] |
| const Section* llvm::TargetAsmInfo::getTLSBSSSection | ( | ) | const [inline] |
| const char* llvm::TargetAsmInfo::getZeroFillDirective | ( | ) | const [inline] |
Definition at line 619 of file TargetAsmInfo.h.
References ZeroFillDirective.
Referenced by llvm::X86ATTAsmPrinter::printModuleLevelGV().
| const char* llvm::TargetAsmInfo::getNonexecutableStackDirective | ( | ) | const [inline] |
Definition at line 622 of file TargetAsmInfo.h.
References NonexecutableStackDirective.
Referenced by llvm::AsmPrinter::doFinalization().
| bool llvm::TargetAsmInfo::needsSet | ( | ) | const [inline] |
| const char* llvm::TargetAsmInfo::getPCSymbol | ( | ) | const [inline] |
| char llvm::TargetAsmInfo::getSeparatorChar | ( | ) | const [inline] |
| const char* llvm::TargetAsmInfo::getCommentString | ( | ) | const [inline] |
Definition at line 634 of file TargetAsmInfo.h.
References CommentString.
Referenced by llvm::X86IntelAsmPrinter::doFinalization(), llvm::AsmPrinter::doInitialization(), llvm::AsmPrinter::EmitGlobalConstant(), llvm::AsmPrinter::EOL(), llvm::AsmPrinter::printBasicBlockLabel(), llvm::AsmPrinter::printImplicitDef(), llvm::X86ATTAsmPrinter::printModuleLevelGV(), printSOImm(), and llvm::AsmPrinter::PrintSpecial().
| const char* llvm::TargetAsmInfo::getGlobalPrefix | ( | ) | const [inline] |
Definition at line 637 of file TargetAsmInfo.h.
References GlobalPrefix.
Referenced by llvm::AsmPrinter::doInitialization(), EmitCamlGlobal(), llvm::AsmPrinter::getCurrentFunctionEHName(), llvm::MachOSym::MachOSym(), llvm::X86IntelAsmPrinter::printOp(), and llvm::X86ATTAsmPrinter::printOperand().
| const char* llvm::TargetAsmInfo::getPrivateGlobalPrefix | ( | ) | const [inline] |
Definition at line 640 of file TargetAsmInfo.h.
References PrivateGlobalPrefix.
Referenced by llvm::AsmPrinter::EmitConstantPool(), llvm::AsmPrinter::EmitJumpTableInfo(), llvm::DarwinTargetAsmInfo::emitUsedDirectiveFor(), llvm::AsmPrinter::printBasicBlockLabel(), llvm::AsmPrinter::printLabel(), llvm::X86IntelAsmPrinter::printOp(), llvm::X86ATTAsmPrinter::printOperand(), llvm::X86ATTAsmPrinter::printPICJumpTableEntry(), llvm::AsmPrinter::printPICJumpTableEntry(), llvm::X86IntelAsmPrinter::printPICJumpTableSetLabel(), llvm::X86ATTAsmPrinter::printPICJumpTableSetLabel(), llvm::AsmPrinter::printPICJumpTableSetLabel(), llvm::AsmPrinter::PrintSpecial(), and llvm::AsmPrinter::printSuffixedName().
| const char* llvm::TargetAsmInfo::getLessPrivateGlobalPrefix | ( | ) | const [inline] |
Definition at line 643 of file TargetAsmInfo.h.
References LessPrivateGlobalPrefix.
Referenced by llvm::DarwinTargetAsmInfo::emitUsedDirectiveFor().
| const char* llvm::TargetAsmInfo::getJumpTableSpecialLabelPrefix | ( | ) | const [inline] |
Definition at line 646 of file TargetAsmInfo.h.
References JumpTableSpecialLabelPrefix.
Referenced by llvm::AsmPrinter::EmitJumpTableInfo().
| const char* llvm::TargetAsmInfo::getGlobalVarAddrPrefix | ( | ) | const [inline] |
Definition at line 649 of file TargetAsmInfo.h.
References GlobalVarAddrPrefix.
Referenced by llvm::AsmPrinter::EmitConstantValueOnly(), and llvm::AsmPrinter::getGlobalLinkName().
| const char* llvm::TargetAsmInfo::getGlobalVarAddrSuffix | ( | ) | const [inline] |
Definition at line 652 of file TargetAsmInfo.h.
References GlobalVarAddrSuffix.
Referenced by llvm::AsmPrinter::EmitConstantValueOnly(), and llvm::AsmPrinter::getGlobalLinkName().
| const char* llvm::TargetAsmInfo::getFunctionAddrPrefix | ( | ) | const [inline] |
Definition at line 655 of file TargetAsmInfo.h.
References FunctionAddrPrefix.
Referenced by llvm::AsmPrinter::EmitConstantValueOnly(), and llvm::AsmPrinter::getGlobalLinkName().
| const char* llvm::TargetAsmInfo::getFunctionAddrSuffix | ( | ) | const [inline] |
Definition at line 658 of file TargetAsmInfo.h.
References FunctionAddrSuffix.
Referenced by llvm::AsmPrinter::EmitConstantValueOnly(), and llvm::AsmPrinter::getGlobalLinkName().
| const char* llvm::TargetAsmInfo::getPersonalityPrefix | ( | ) | const [inline] |
| const char* llvm::TargetAsmInfo::getPersonalitySuffix | ( | ) | const [inline] |
| bool llvm::TargetAsmInfo::getNeedsIndirectEncoding | ( | ) | const [inline] |
Definition at line 667 of file TargetAsmInfo.h.
References NeedsIndirectEncoding.
Referenced by llvm::JITDwarfEmitter::EmitDwarfTable(), and llvm::JITDwarfEmitter::GetDwarfTableSizeInBytes().
| const char* llvm::TargetAsmInfo::getInlineAsmStart | ( | ) | const [inline] |
Definition at line 670 of file TargetAsmInfo.h.
References InlineAsmStart.
Referenced by llvm::AsmPrinter::printInlineAsm().
| const char* llvm::TargetAsmInfo::getInlineAsmEnd | ( | ) | const [inline] |
Definition at line 673 of file TargetAsmInfo.h.
References InlineAsmEnd.
Referenced by llvm::AsmPrinter::printInlineAsm().
| unsigned llvm::TargetAsmInfo::getAssemblerDialect | ( | ) | const [inline] |
Definition at line 676 of file TargetAsmInfo.h.
References AssemblerDialect.
Referenced by llvm::AsmPrinter::printInlineAsm().
| const char* llvm::TargetAsmInfo::getStringConstantPrefix | ( | ) | const [inline] |
| const char* llvm::TargetAsmIn |