LLVM API Documentation

llvm::AsmPrinter Class Reference

#include <AsmPrinter.h>

Inheritance diagram for llvm::AsmPrinter:

Inheritance graph
[legend]
Collaboration diagram for llvm::AsmPrinter:

Collaboration graph
[legend]
List of all members.

Public Member Functions

void SwitchToTextSection (const char *NewSection, const GlobalValue *GV)
void SwitchToDataSection (const char *NewSection, const GlobalValue *GV)
unsigned getPreferredAlignmentLog (const GlobalVariable *GV) const

Public Attributes

std::ostream & O
TargetMachineTM
ManglerMang
std::string CurrentFnName
const char * CommentString
const char * GlobalPrefix
const char * PrivateGlobalPrefix
const char * GlobalVarAddrPrefix
const char * GlobalVarAddrSuffix
const char * FunctionAddrPrefix
const char * FunctionAddrSuffix
const char * InlineAsmStart
const char * InlineAsmEnd
const char * ZeroDirective
const char * ZeroDirectiveSuffix
const char * AsciiDirective
const char * AscizDirective
const char * Data8bitsDirective
const char * Data16bitsDirective
const char * Data32bitsDirective
const char * Data64bitsDirective
const char * AlignDirective
bool AlignmentIsInBytes
std::string CurrentSection
const char * SwitchToSectionDirective
const char * TextSectionStartSuffix
const char * DataSectionStartSuffix
const char * SectionEndDirectiveSuffix
const char * ConstantPoolSection
const char * JumpTableDataSection
const char * JumpTableTextSection
const char * StaticCtorsSection
const char * StaticDtorsSection
const char * FourByteConstantSection
const char * EightByteConstantSection
const char * SixteenByteConstantSection
const char * LCOMMDirective
const char * COMMDirective
bool COMMDirectiveTakesAlignment
bool HasDotTypeDotSizeDirective

Protected Member Functions

 AsmPrinter (std::ostream &o, TargetMachine &TM)
bool doInitialization (Module &M)
bool doFinalization (Module &M)
virtual bool PrintAsmOperand (const MachineInstr *MI, unsigned OpNo, unsigned AsmVariant, const char *ExtraCode)
virtual bool PrintAsmMemoryOperand (const MachineInstr *MI, unsigned OpNo, unsigned AsmVariant, const char *ExtraCode)
void SetupMachineFunction (MachineFunction &MF)
unsigned getFunctionNumber () const
void IncrementFunctionNumber ()
void EmitConstantPool (MachineConstantPool *MCP)
void EmitJumpTableInfo (MachineJumpTableInfo *MJTI)
bool EmitSpecialLLVMGlobal (const GlobalVariable *GV)
void EmitAlignment (unsigned NumBits, const GlobalValue *GV=0) const
void EmitZeros (uint64_t NumZeros) const
virtual void EmitString (const ConstantArray *CVA) const
void EmitConstantValueOnly (const Constant *CV)
void EmitGlobalConstant (const Constant *CV)
void printInlineAsm (const MachineInstr *MI) const
virtual void printBasicBlockLabel (const MachineBasicBlock *MBB, bool printColon=false, bool printComment=true) const

Detailed Description

Definition at line 29 of file AsmPrinter.h.


Constructor & Destructor Documentation

AsmPrinter::AsmPrinter ( std::ostream &  o,
TargetMachine TM 
) [protected]

Definition at line 29 of file AsmPrinter.cpp.


Member Function Documentation

void AsmPrinter::SwitchToTextSection ( const char *  NewSection,
const GlobalValue GV 
)

SwitchToTextSection - Switch to the specified section of the executable if we are not already in it! If GV is non-null and if the global has an explicitly requested section, we switch to the section indicated for the global instead of NewSection.

If the new section is an empty string, this method forgets what the current section is, but does not emit a .section directive.

This method is used when about to emit executable code.

Definition at line 72 of file AsmPrinter.cpp.

References CurrentSection, llvm::GlobalValue::getSection(), GV, llvm::GlobalValue::hasSection(), O, SectionEndDirectiveSuffix, SwitchToSectionDirective, and TextSectionStartSuffix.

Referenced by EmitJumpTableInfo(), llvm::DwarfWriter::EndModule(), llvm::X86IntelAsmPrinter::runOnMachineFunction(), and llvm::X86ATTAsmPrinter::runOnMachineFunction().

void AsmPrinter::SwitchToDataSection ( const char *  NewSection,
const GlobalValue GV 
)

SwitchToDataSection - Switch to the specified section of the executable if we are not already in it! If GV is non-null and if the global has an explicitly requested section, we switch to the section indicated for the global instead of NewSection.

If the new section is an empty string, this method forgets what the current section is, but does not emit a .section directive.

This method is used when about to emit data. For most assemblers, this is the same as the SwitchToTextSection method, but not all assemblers are the same.

Definition at line 96 of file AsmPrinter.cpp.

References CurrentSection, DataSectionStartSuffix, llvm::GlobalValue::getSection(), GV, llvm::GlobalValue::hasSection(), O, SectionEndDirectiveSuffix, and SwitchToSectionDirective.

Referenced by llvm::X86IntelAsmPrinter::doFinalization(), llvm::X86SharedAsmPrinter::doFinalization(), doInitialization(), EmitJumpTableInfo(), EmitSpecialLLVMGlobal(), and llvm::DwarfWriter::EndModule().

unsigned AsmPrinter::getPreferredAlignmentLog ( const GlobalVariable GV  )  const

getPreferredAlignmentLog - Return the preferred alignment of the specified global, returned in log form. This includes an explicitly requested alignment (if the global has one).

Definition at line 294 of file AsmPrinter.cpp.

References llvm::Type::DoubleTy, llvm::GlobalValue::getAlignment(), llvm::SequentialType::getElementType(), llvm::TargetMachine::getTargetData(), llvm::GlobalValue::getType(), llvm::TargetData::getTypeAlignmentShift(), llvm::TargetData::getTypeSize(), GV, llvm::Log2_32(), TM, and U.

Referenced by llvm::X86IntelAsmPrinter::doFinalization(), and llvm::X86SharedAsmPrinter::doFinalization().

bool AsmPrinter::doInitialization ( Module M  )  [protected, virtual]

doInitialization - Set up the AsmPrinter when we are working on a new module. If your pass overrides this, it must make sure to explicitly call this implementation.

Reimplemented from llvm::FunctionPass.

Reimplemented in llvm::X86SharedAsmPrinter, and llvm::X86IntelAsmPrinter.

Definition at line 118 of file AsmPrinter.cpp.

References CommentString, llvm::Module::getModuleInlineAsm(), GlobalPrefix, M, Mang, O, and SwitchToDataSection().

Referenced by llvm::X86SharedAsmPrinter::doInitialization().

bool AsmPrinter::doFinalization ( Module M  )  [protected, virtual]

doFinalization - Shut down the asmprinter. If you override this in your pass, you must make sure to call it explicitly.

Reimplemented from llvm::FunctionPass.

Reimplemented in llvm::X86SharedAsmPrinter, and llvm::X86IntelAsmPrinter.

Definition at line 135 of file AsmPrinter.cpp.

References Mang.

Referenced by llvm::X86IntelAsmPrinter::doFinalization(), and llvm::X86SharedAsmPrinter::doFinalization().

bool AsmPrinter::PrintAsmOperand ( const MachineInstr MI,
unsigned  OpNo,
unsigned  AsmVariant,
const char *  ExtraCode 
) [protected, virtual]

PrintAsmOperand - Print the specified operand of MI, an INLINEASM instruction, using the specified assembler variant. Targets should override this to format as appropriate. This method can return true if the operand is erroneous.

Reimplemented in llvm::X86ATTAsmPrinter, and llvm::X86IntelAsmPrinter.

Definition at line 779 of file AsmPrinter.cpp.

Referenced by printInlineAsm().

bool AsmPrinter::PrintAsmMemoryOperand ( const MachineInstr MI,
unsigned  OpNo,
unsigned  AsmVariant,
const char *  ExtraCode 
) [protected, virtual]

PrintAsmMemoryOperand - Print the specified operand of MI, an INLINEASM instruction, using the specified assembler variant as an address. Targets should override this to format as appropriate. This method can return true if the operand is erroneous.

Reimplemented in llvm::X86ATTAsmPrinter, and llvm::X86IntelAsmPrinter.

Definition at line 785 of file AsmPrinter.cpp.

Referenced by printInlineAsm().

void AsmPrinter::SetupMachineFunction ( MachineFunction MF  )  [protected]

SetupMachineFunction - This should be called when a new MachineFunction is being processed from runOnMachineFunction.

Definition at line 140 of file AsmPrinter.cpp.

References CurrentFnName, llvm::MachineFunction::getFunction(), llvm::Mangler::getValueName(), IncrementFunctionNumber(), Mang, and MF.

Referenced by llvm::X86IntelAsmPrinter::runOnMachineFunction(), and llvm::X86ATTAsmPrinter::runOnMachineFunction().

unsigned llvm::AsmPrinter::getFunctionNumber (  )  const [inline, protected]

getFunctionNumber - Return a unique ID for the current function.

Definition at line 270 of file AsmPrinter.h.

Referenced by EmitJumpTableInfo(), llvm::X86IntelAsmPrinter::printOp(), llvm::X86ATTAsmPrinter::printOperand(), llvm::X86IntelAsmPrinter::printPICLabel(), and llvm::X86ATTAsmPrinter::printPICLabel().

void llvm::AsmPrinter::IncrementFunctionNumber (  )  [inline, protected]

IncrementFunctionNumber - Increase Function Number. AsmPrinters should not normally call this, as the counter is automatically bumped by SetupMachineFunction.

Definition at line 275 of file AsmPrinter.h.

Referenced by SetupMachineFunction().

void AsmPrinter::EmitConstantPool ( MachineConstantPool MCP  )  [protected]

EmitConstantPool - Print to the current output stream assembly representations of the constants in the constant pool MCP. This is used to print out constants which have been "spilled to memory" by the code generator.

Definition at line 151 of file AsmPrinter.cpp.

References ConstantPoolSection, CP, EightByteConstantSection, FourByteConstantSection, llvm::MachineConstantPool::getConstantPoolAlignment(), llvm::MachineConstantPool::getConstants(), llvm::TargetMachine::getTargetData(), llvm::Value::getType(), llvm::TargetData::getTypeSize(), SixteenByteConstantSection, TM, and Ty.

Referenced by llvm::X86IntelAsmPrinter::runOnMachineFunction(), and llvm::X86ATTAsmPrinter::runOnMachineFunction().

void AsmPrinter::EmitJumpTableInfo ( MachineJumpTableInfo MJTI  )  [protected]

EmitJumpTableInfo - Print assembly representations of the jump tables used by the current function to the current output stream.

Definition at line 209 of file AsmPrinter.cpp.

References Data32bitsDirective, Data64bitsDirective, EmitAlignment(), getFunctionNumber(), llvm::MachineJumpTableInfo::getJumpTables(), llvm::TargetData::getPointerAlignment(), llvm::TargetData::getPointerSize(), llvm::TargetMachine::getRelocationModel(), llvm::TargetMachine::getTargetData(), JumpTableDataSection, JumpTableTextSection, llvm::Log2_32(), O, llvm::Reloc::PIC_, printBasicBlockLabel(), PrivateGlobalPrefix, SwitchToDataSection(), SwitchToTextSection(), TD, and TM.

Referenced by llvm::X86ATTAsmPrinter::runOnMachineFunction().

bool AsmPrinter::EmitSpecialLLVMGlobal ( const GlobalVariable GV  )  [protected]

EmitSpecialLLVMGlobal - Check to see if the specified global is a special global used by LLVM. If so, emit it and return true, otherwise do nothing and return false.

Definition at line 245 of file AsmPrinter.cpp.

References EmitAlignment(), llvm::Value::getName(), llvm::GlobalValue::getSection(), GV, llvm::GlobalValue::hasAppendingLinkage(), StaticCtorsSection, StaticDtorsSection, SwitchToDataSection(), and llvm::Value::use_empty().

Referenced by llvm::X86IntelAsmPrinter::doFinalization(), and llvm::X86SharedAsmPrinter::doFinalization().

void AsmPrinter::EmitAlignment ( unsigned  NumBits,
const GlobalValue GV = 0 
) const [protected]

EmitAlignment - Emit an alignment directive to the specified power of two boundary. For example, if you pass in 3 here, you will get an 8 byte alignment. If a global value is specified, and if that global has an explicit alignment requested, it will override the alignment request.

Definition at line 315 of file AsmPrinter.cpp.

References AlignDirective, AlignmentIsInBytes, llvm::GlobalValue::getAlignment(), GV, llvm::Log2_32(), and O.

Referenced by llvm::X86IntelAsmPrinter::doFinalization(), llvm::X86SharedAsmPrinter::doFinalization(), EmitJumpTableInfo(), EmitSpecialLLVMGlobal(), llvm::X86IntelAsmPrinter::runOnMachineFunction(), and llvm::X86ATTAsmPrinter::runOnMachineFunction().

void AsmPrinter::EmitZeros ( uint64_t  NumZeros  )  const [protected]

EmitZeros - Emit a block of zeros.

Definition at line 325 of file AsmPrinter.cpp.

References Data8bitsDirective, O, ZeroDirective, and ZeroDirectiveSuffix.

Referenced by EmitGlobalConstant().

void AsmPrinter::EmitString ( const ConstantArray CVA  )  const [protected, virtual]

EmitString - Emit a zero-byte-terminated string constant.

Reimplemented in llvm::X86IntelAsmPrinter.

Definition at line 464 of file AsmPrinter.cpp.

References AsciiDirective, AscizDirective, llvm::User::getNumOperands(), llvm::Constant::getOperand(), O, and printAsCString().

Referenced by EmitGlobalConstant().

void AsmPrinter::EmitConstantValueOnly ( const Constant CV  )  [protected]

EmitConstantValueOnly - Print out the specified constant, without a storage class. Only constants of first-class type are allowed here.

Definition at line 341 of file AsmPrinter.cpp.

References llvm::Instruction::Cast, FunctionAddrPrefix, FunctionAddrSuffix, llvm::TargetData::getIndexedOffset(), llvm::TargetMachine::getTargetData(), llvm::TargetData::getTypeSize(), llvm::Mangler::getValueName(), GlobalVarAddrPrefix, GlobalVarAddrSuffix, GV, llvm::Type::IntTy, llvm::Constant::isNullValue(), llvm::Type::LongTy, Mang, O, Offset, Op, TD, TM, llvm::ConstantBool::True, Ty, llvm::Type::UIntTy, and llvm::Type::ULongTy.

Referenced by EmitGlobalConstant().

void AsmPrinter::EmitGlobalConstant ( const Constant CV  )  [protected]

EmitGlobalConstant - Print a general LLVM constant to the .s file.

Definition at line 479 of file AsmPrinter.cpp.

References llvm::Type::BoolTyID, CommentString, CP, Data16bitsDirective, Data32bitsDirective, Data64bitsDirective, Data8bitsDirective, llvm::DoubleToBits(), llvm::Type::DoubleTy, llvm::Type::DoubleTyID, E, EmitConstantValueOnly(), EmitString(), EmitZeros(), llvm::FloatToBits(), llvm::Type::FloatTyID, llvm::PackedType::getNumElements(), llvm::Constant::getOperand(), llvm::TargetData::getPointerSize(), llvm::TargetData::getStructLayout(), llvm::TargetMachine::getTargetData(), llvm::Value::getType(), llvm::Type::getTypeID(), llvm::TargetData::getTypeSize(), llvm::Type::IntTyID, llvm::TargetData::isBigEndian(), llvm::Constant::isNullValue(), llvm::Type::LongTy, llvm::Type::LongTyID, llvm::StructLayout::MemberOffsets, O, llvm::Type::PointerTyID, llvm::Type::SByteTyID, llvm::Type::ShortTyID, llvm::StructLayout::StructSize, TD, TM, llvm::Type::UByteTyID, llvm::Type::UIntTyID, llvm::Type::ULongTy, llvm::Type::ULongTyID, llvm::Type::UShortTyID, and Val.

Referenced by llvm::X86IntelAsmPrinter::doFinalization(), and llvm::X86SharedAsmPrinter::doFinalization().

void AsmPrinter::printInlineAsm ( const MachineInstr MI  )  const [protected]

printInlineAsm - This method formats and prints the specified machine instruction that is an inline asm.

Definition at line 613 of file AsmPrinter.cpp.

References llvm::MachineInstr::dump(), Error(), llvm::MachineOperand::getImmedValue(), llvm::MachineInstr::getNumOperands(), llvm::MachineInstr::getOperand(), llvm::MachineOperand::getSymbolName(), InlineAsmEnd, InlineAsmStart, llvm::MachineOperand::isDef(), llvm::MachineOperand::isExternalSymbol(), MI, O, PrintAsmMemoryOperand(), PrintAsmOperand(), and Val.

void AsmPrinter::printBasicBlockLabel ( const MachineBasicBlock MBB,
bool  printColon = false,
bool  printComment = true 
) const [protected, virtual]

printBasicBlockLabel - This method prints the label for the specified MachineBasicBlock

Definition at line 794 of file AsmPrinter.cpp.

References CommentString, llvm::MachineBasicBlock::getBasicBlock(), llvm::Value::getName(), llvm::MachineBasicBlock::getNumber(), MBB, O, and PrivateGlobalPrefix.

Referenced by EmitJumpTableInfo(), llvm::X86IntelAsmPrinter::printOp(), llvm::X86ATTAsmPrinter::printOperand(), llvm::X86IntelAsmPrinter::runOnMachineFunction(), and llvm::X86ATTAsmPrinter::runOnMachineFunction().


Member Data Documentation

std::ostream& llvm::AsmPrinter::O

Output stream on which we're printing assembly code.

Definition at line 40 of file AsmPrinter.h.

Referenced by llvm::X86IntelAsmPrinter::doFinalization(), llvm::X86SharedAsmPrinter::doFinalization(), llvm::X86IntelAsmPrinter::doInitialization(), doInitialization(), EmitAlignment(), EmitConstantValueOnly(), EmitGlobalConstant(), EmitJumpTableInfo(), llvm::X86IntelAsmPrinter::EmitString(), EmitString(), EmitZeros(), llvm::X86IntelAsmPrinter::printAsmMRegister(), llvm::X86ATTAsmPrinter::printAsmMRegister(), printBasicBlockLabel(), printInlineAsm(), llvm::X86IntelAsmPrinter::printMachineInstruction(), llvm::X86ATTAsmPrinter::printMachineInstruction(), llvm::X86IntelAsmPrinter::printMemReference(), llvm::X86ATTAsmPrinter::printMemReference(), llvm::X86IntelAsmPrinter::printOp(), llvm::X86ATTAsmPrinter::printOperand(), llvm::X86IntelAsmPrinter::printPICLabel(), llvm::X86ATTAsmPrinter::printPICLabel(), llvm::X86IntelAsmPrinter::printSSECC(), llvm::X86ATTAsmPrinter::printSSECC(), llvm::X86IntelAsmPrinter::runOnMachineFunction(), llvm::X86ATTAsmPrinter::runOnMachineFunction(), SwitchToDataSection(), and SwitchToTextSection().

TargetMachine& llvm::AsmPrinter::TM

Target machine description.

Definition at line 44 of file AsmPrinter.h.

Referenced by llvm::X86IntelAsmPrinter::doFinalization(), llvm::X86SharedAsmPrinter::doFinalization(), EmitConstantPool(), EmitConstantValueOnly(), EmitGlobalConstant(), EmitJumpTableInfo(), getPreferredAlignmentLog(), llvm::X86IntelAsmPrinter::printAsmMRegister(), llvm::X86ATTAsmPrinter::printAsmMRegister(), llvm::X86IntelAsmPrinter::printOp(), llvm::X86IntelAsmPrinter::printOperand(), llvm::X86ATTAsmPrinter::printOperand(), and llvm::X86SharedAsmPrinter::X86SharedAsmPrinter().

Mangler* llvm::AsmPrinter::Mang

Name-mangler for global names.

Definition at line 48 of file AsmPrinter.h.

Referenced by llvm::X86IntelAsmPrinter::doFinalization(), llvm::X86SharedAsmPrinter::doFinalization(), doFinalization(), llvm::X86IntelAsmPrinter::doInitialization(), doInitialization(), EmitConstantValueOnly(), llvm::X86IntelAsmPrinter::printOp(), llvm::X86ATTAsmPrinter::printOperand(), and SetupMachineFunction().

std::string llvm::AsmPrinter::CurrentFnName

Cache of mangled name for current function. This is recalculated at the beginning of each call to runOnMachineFunction().

Definition at line 53 of file AsmPrinter.h.

Referenced by llvm::X86IntelAsmPrinter::runOnMachineFunction(), llvm::X86ATTAsmPrinter::runOnMachineFunction(), and SetupMachineFunction().

const char* llvm::AsmPrinter::CommentString

CommentString - This indicates the comment character used by the assembler.

Definition at line 61 of file AsmPrinter.h.

Referenced by llvm::X86IntelAsmPrinter::doFinalization(), llvm::X86SharedAsmPrinter::doFinalization(), llvm::X86IntelAsmPrinter::doInitialization(), doInitialization(), EmitGlobalConstant(), llvm::DwarfWriter::EOL(), printBasicBlockLabel(), llvm::X86IntelAsmPrinter::printMachineInstruction(), and llvm::X86ATTAsmPrinter::printMachineInstruction().

const char* llvm::AsmPrinter::GlobalPrefix

GlobalPrefix - If this is set to a non-empty string, it is prepended onto all global symbols. This is often used for "_" or ".".

Definition at line 65 of file AsmPrinter.h.

Referenced by llvm::X86IntelAsmPrinter::doInitialization(), llvm::X86SharedAsmPrinter::doInitialization(), doInitialization(), llvm::X86IntelAsmPrinter::printOp(), and llvm::X86ATTAsmPrinter::printOperand().

const char* llvm::AsmPrinter::PrivateGlobalPrefix

PrivateGlobalPrefix - This prefix is used for globals like constant pool entries that are completely private to the .o file and should not have names in the .o file. This is often "." or "L".

Definition at line 70 of file AsmPrinter.h.

Referenced by llvm::X86IntelAsmPrinter::doInitialization(), llvm::X86SharedAsmPrinter::doInitialization(), EmitJumpTableInfo(), printBasicBlockLabel(), llvm::DwarfWriter::PrintLabelName(), llvm::X86IntelAsmPrinter::printOp(), and llvm::X86ATTAsmPrinter::printOperand().

const char* llvm::AsmPrinter::GlobalVarAddrPrefix

GlobalVarAddrPrefix/Suffix - If these are nonempty, these strings will enclose any GlobalVariable (that isn't a function)

Definition at line 75 of file AsmPrinter.h.

Referenced by EmitConstantValueOnly().

const char* llvm::AsmPrinter::GlobalVarAddrSuffix

Definition at line 76 of file AsmPrinter.h.

Referenced by EmitConstantValueOnly().

const char* llvm::AsmPrinter::FunctionAddrPrefix

FunctionAddrPrefix/Suffix - If these are nonempty, these strings will enclose any GlobalVariable that points to a function. For example, this is used by the IA64 backend to materialize function descriptors, by decorating the ".data8" object with the ( ) link-relocation operator.

Definition at line 85 of file AsmPrinter.h.

Referenced by EmitConstantValueOnly().

const char* llvm::AsmPrinter::FunctionAddrSuffix

Definition at line 86 of file AsmPrinter.h.

Referenced by EmitConstantValueOnly().

const char* llvm::AsmPrinter::InlineAsmStart

InlineAsmStart/End - If these are nonempty, they contain a directive to emit before and after an inline assmebly statement.

Definition at line 90 of file AsmPrinter.h.

Referenced by llvm::X86SharedAsmPrinter::doInitialization(), and printInlineAsm().

const char* llvm::AsmPrinter::InlineAsmEnd

Definition at line 91 of file AsmPrinter.h.

Referenced by llvm::X86SharedAsmPrinter::doInitialization(), and printInlineAsm().

const char* llvm::AsmPrinter::ZeroDirective

ZeroDirective - this should be set to the directive used to get some number of zero bytes emitted to the current section. Common cases are "\t.zero\t" and "\t.space\t". If this is set to null, the Data*bitsDirective's will be used to emit zero bytes.

Definition at line 99 of file AsmPrinter.h.

Referenced by llvm::X86IntelAsmPrinter::doInitialization(), llvm::X86SharedAsmPrinter::doInitialization(), and EmitZeros().

const char* llvm::AsmPrinter::ZeroDirectiveSuffix

Definition at line 100 of file AsmPrinter.h.

Referenced by llvm::X86IntelAsmPrinter::doInitialization(), and EmitZeros().

const char* llvm::AsmPrinter::AsciiDirective

AsciiDirective - This directive allows emission of an ascii string with the standard C escape characters embedded into it.

Definition at line 104 of file AsmPrinter.h.

Referenced by llvm::X86IntelAsmPrinter::doInitialization(), llvm::DwarfWriter::EmitString(), and EmitString().

const char* llvm::AsmPrinter::AscizDirective

AscizDirective - If not null, this allows for special handling of zero terminated strings on this target. This is commonly supported as ".asciz". If a target doesn't support this, it can be set to null.

Definition at line 109 of file AsmPrinter.h.

Referenced by llvm::X86IntelAsmPrinter::doInitialization(), and EmitString().

const char* llvm::AsmPrinter::Data8bitsDirective

DataDirectives - These directives are used to output some unit of integer data to the current section. If a data directive is set to null, smaller data directives will be used to emit the large sizes.

Definition at line 114 of file AsmPrinter.h.

Referenced by llvm::X86IntelAsmPrinter::doInitialization(), EmitGlobalConstant(), llvm::DwarfWriter::EmitInt8(), llvm::DwarfWriter::EmitSLEB128Bytes(), llvm::DwarfWriter::EmitULEB128Bytes(), and EmitZeros().

const char* llvm::AsmPrinter::Data16bitsDirective

Definition at line 115 of file AsmPrinter.h.

Referenced by llvm::X86IntelAsmPrinter::doInitialization(), EmitGlobalConstant(), and llvm::DwarfWriter::EmitInt16().

const char* llvm::AsmPrinter::Data32bitsDirective

Definition at line 116 of file AsmPrinter.h.

Referenced by llvm::X86IntelAsmPrinter::doInitialization(), llvm::DwarfWriter::EmitDifference(), EmitGlobalConstant(), llvm::DwarfWriter::EmitInt32(), EmitJumpTableInfo(), and llvm::DwarfWriter::EmitReference().

const char* llvm::AsmPrinter::Data64bitsDirective

Definition at line 117 of file AsmPrinter.h.

Referenced by llvm::X86IntelAsmPrinter::doInitialization(), llvm::X86SharedAsmPrinter::doInitialization(), llvm::DwarfWriter::EmitDifference(), EmitGlobalConstant(), llvm::DwarfWriter::EmitInt64(), EmitJumpTableInfo(), and llvm::DwarfWriter::EmitReference().

const char* llvm::AsmPrinter::AlignDirective

AlignDirective - The directive used to emit round up to an alignment boundary.

Definition at line 124 of file AsmPrinter.h.

Referenced by llvm::X86IntelAsmPrinter::doInitialization(), llvm::DwarfWriter::EmitAlign(), and EmitAlignment().

bool llvm::AsmPrinter::AlignmentIsInBytes

AlignmentIsInBytes - If this is true (the default) then the asmprinter emits ".align N" directives, where N is the number of bytes to align to. Otherwise, it emits ".align log2(N)", e.g. 3 to align to an 8 byte boundary.

Definition at line 130 of file AsmPrinter.h.

Referenced by llvm::X86SharedAsmPrinter::doFinalization(), llvm::X86SharedAsmPrinter::doInitialization(), and EmitAlignment().

std::string llvm::AsmPrinter::CurrentSection

CurrentSection - The current section we are emitting to. This is controlled and used by the SwitchSection method.

Definition at line 136 of file AsmPrinter.h.

Referenced by llvm::DwarfWriter::EndFunction(), SwitchToDataSection(), and SwitchToTextSection().

const char* llvm::AsmPrinter::SwitchToSectionDirective

SwitchToSectionDirective - This is the directive used when we want to emit a global to an arbitrary section. The section name is emited after this.

Definition at line 141 of file AsmPrinter.h.

Referenced by llvm::X86IntelAsmPrinter::doInitialization(), SwitchToDataSection(), and SwitchToTextSection().

const char* llvm::AsmPrinter::TextSectionStartSuffix

TextSectionStartSuffix - This is printed after each start of section directive for text sections.

Definition at line 145 of file AsmPrinter.h.

Referenced by llvm::X86IntelAsmPrinter::doInitialization(), and SwitchToTextSection().

const char* llvm::AsmPrinter::DataSectionStartSuffix

DataSectionStartSuffix - This is printed after each start of section directive for data sections.

Definition at line 149 of file AsmPrinter.h.

Referenced by llvm::X86IntelAsmPrinter::doInitialization(), and SwitchToDataSection().

const char* llvm::AsmPrinter::SectionEndDirectiveSuffix

SectionEndDirectiveSuffix - If non-null, the asm printer will close each section with the section name and this suffix printed.

Definition at line 153 of file AsmPrinter.h.

Referenced by llvm::X86IntelAsmPrinter::doInitialization(), SwitchToDataSection(), and SwitchToTextSection().

const char* llvm::AsmPrinter::ConstantPoolSection

ConstantPoolSection - This is the section that we SwitchToSection right before emitting the constant pool for a function.

Definition at line 157 of file AsmPrinter.h.

Referenced by llvm::X86SharedAsmPrinter::doInitialization(), and EmitConstantPool().

const char* llvm::AsmPrinter::JumpTableDataSection

JumpTableDataSection - This is the section that we SwitchToSection right before emitting the jump tables for a function when the relocation model is not PIC.

Definition at line 162 of file AsmPrinter.h.

Referenced by llvm::X86SharedAsmPrinter::doInitialization(), and EmitJumpTableInfo().

const char* llvm::AsmPrinter::JumpTableTextSection

JumpTableTextSection - This is the section that we SwitchToSection right before emitting the jump tables for a function when the relocation model is PIC.

Definition at line 167 of file AsmPrinter.h.

Referenced by EmitJumpTableInfo().

const char* llvm::AsmPrinter::StaticCtorsSection

StaticCtorsSection - This is the directive that is emitted to switch to a section to emit the static constructor list. Defaults to "\t.section .ctors,\"aw\",@progbits".

Definition at line 172 of file AsmPrinter.h.

Referenced by llvm::X86SharedAsmPrinter::doInitialization(), and EmitSpecialLLVMGlobal().

const char* llvm::AsmPrinter::StaticDtorsSection

StaticDtorsSection - This is the directive that is emitted to switch to a section to emit the static destructor list. Defaults to "\t.section .dtors,\"aw\",@progbits".

Definition at line 177 of file AsmPrinter.h.

Referenced by llvm::X86SharedAsmPrinter::doInitialization(), and EmitSpecialLLVMGlobal().

const char* llvm::AsmPrinter::FourByteConstantSection

FourByteConstantSection, EightByteConstantSection, SixteenByteConstantSection - These are special sections where we place 4-, 8-, and 16- byte constant literals.

Definition at line 182 of file AsmPrinter.h.

Referenced by llvm::X86SharedAsmPrinter::doInitialization(), and EmitConstantPool().

const char* llvm::AsmPrinter::EightByteConstantSection

Definition at line 183 of file AsmPrinter.h.

Referenced by llvm::X86SharedAsmPrinter::doInitialization(), and EmitConstantPool().

const char* llvm::AsmPrinter::SixteenByteConstantSection

Definition at line 184 of file AsmPrinter.h.

Referenced by EmitConstantPool().

const char* llvm::AsmPrinter::LCOMMDirective

LCOMMDirective - This is the name of a directive (if supported) that can be used to efficiently declare a local (internal) block of zero initialized data in the .bss/.data section. The syntax expected is: <LCOMMDirective> SYMBOLNAME LENGTHINBYTES, ALIGNMENT

Definition at line 193 of file AsmPrinter.h.

Referenced by llvm::X86SharedAsmPrinter::doFinalization(), and llvm::X86SharedAsmPrinter::doInitialization().

const char* llvm::AsmPrinter::COMMDirective

Definition at line 195 of file AsmPrinter.h.

Referenced by llvm::X86SharedAsmPrinter::doFinalization().

bool llvm::AsmPrinter::COMMDirectiveTakesAlignment

COMMDirectiveTakesAlignment - True if COMMDirective take a third argument that specifies the alignment of the declaration.

Definition at line 199 of file AsmPrinter.h.

Referenced by llvm::X86SharedAsmPrinter::doFinalization(), and llvm::X86SharedAsmPrinter::doInitialization().

bool llvm::AsmPrinter::HasDotTypeDotSizeDirective

HasDotTypeDotSizeDirective - True if the target has .type and .size directives, this is true for most ELF targets.

Definition at line 203 of file AsmPrinter.h.

Referenced by llvm::X86SharedAsmPrinter::doFinalization(), llvm::X86IntelAsmPrinter::doInitialization(), llvm::X86SharedAsmPrinter::doInitialization(), and llvm::X86ATTAsmPrinter::runOnMachineFunction().


The documentation for this class was generated from the following files: