|
LLVM
3.7.0
|
#include <ARMAsmPrinter.h>
Public Member Functions | |
| ARMAsmPrinter (TargetMachine &TM, std::unique_ptr< MCStreamer > Streamer) | |
| const char * | getPassName () const override |
| getPassName - Return a nice clean name for a pass. More... | |
| void | printOperand (const MachineInstr *MI, int OpNum, raw_ostream &O) |
| bool | PrintAsmOperand (const MachineInstr *MI, unsigned OpNum, unsigned AsmVariant, const char *ExtraCode, raw_ostream &O) override |
| Print the specified operand of MI, an INLINEASM instruction, using the specified assembler variant. More... | |
| bool | PrintAsmMemoryOperand (const MachineInstr *MI, unsigned OpNum, unsigned AsmVariant, const char *ExtraCode, raw_ostream &O) override |
| Print the specified operand of MI, an INLINEASM instruction, using the specified assembler variant as an address. More... | |
| void | emitInlineAsmEnd (const MCSubtargetInfo &StartInfo, const MCSubtargetInfo *EndInfo) const override |
| Let the target do anything it needs to do after emitting inlineasm. More... | |
| void | EmitJumpTableAddrs (const MachineInstr *MI) |
| void | EmitJumpTableInsts (const MachineInstr *MI) |
| void | EmitJumpTableTBInst (const MachineInstr *MI, unsigned OffsetWidth) |
| void | EmitInstruction (const MachineInstr *MI) override |
| Targets should implement this to emit instructions. More... | |
| bool | runOnMachineFunction (MachineFunction &F) override |
| runOnMachineFunction - This uses the EmitInstruction() method to print assembly for each instruction. More... | |
| void | EmitConstantPool () override |
| Print to the current output stream assembly representations of the constants in the constant pool MCP. More... | |
| void | EmitFunctionBodyEnd () override |
| Targets can override this to emit stuff after the last basic block in the function. More... | |
| void | EmitFunctionEntryLabel () override |
| EmitFunctionEntryLabel - Emit the label that is the entrypoint for the function. More... | |
| void | EmitStartOfAsmFile (Module &M) override |
| This virtual method can be overridden by targets that want to emit something at the start of their file. More... | |
| void | EmitEndOfAsmFile (Module &M) override |
| This virtual method can be overridden by targets that want to emit something at the end of their file. More... | |
| void | EmitXXStructor (const Constant *CV) override |
| Targets can override this to change how global constants that are part of a C++ static/global constructor list are emitted. More... | |
| bool | lowerOperand (const MachineOperand &MO, MCOperand &MCOp) |
| unsigned | getISAEncoding () override |
| Get the value for DW_AT_APPLE_isa. Zero if no isa encoding specified. More... | |
| void | EmitMachineConstantPoolValue (MachineConstantPoolValue *MCPV) override |
| EmitMachineConstantPoolValue - Print a machine constantpool value to the .s file. More... | |
Public Member Functions inherited from llvm::AsmPrinter | |
| ~AsmPrinter () override | |
| DwarfDebug * | getDwarfDebug () |
| DwarfDebug * | getDwarfDebug () const |
| bool | isVerbose () const |
| Return true if assembly output should contain comments. More... | |
| unsigned | getFunctionNumber () const |
| Return a unique ID for the current function. More... | |
| MCSymbol * | getFunctionBegin () const |
| MCSymbol * | getFunctionEnd () const |
| MCSymbol * | getCurExceptionSym () |
| const TargetLoweringObjectFile & | getObjFileLowering () const |
| Return information about object file lowering. More... | |
| const DataLayout & | getDataLayout () const |
| Return information about data layout. More... | |
| const MCSubtargetInfo & | getSubtargetInfo () const |
| Return information about subtarget. More... | |
| void | EmitToStreamer (MCStreamer &S, const MCInst &Inst) |
| StringRef | getTargetTriple () const |
| Return the target triple string. More... | |
| const MCSection * | getCurrentSection () const |
| Return the current section we are emitting to. More... | |
| void | getNameWithPrefix (SmallVectorImpl< char > &Name, const GlobalValue *GV) const |
| MCSymbol * | getSymbol (const GlobalValue *GV) const |
| void | getAnalysisUsage (AnalysisUsage &AU) const override |
| Record analysis usage. More... | |
| bool | doInitialization (Module &M) override |
| Set up the AsmPrinter when we are working on a new module. More... | |
| bool | doFinalization (Module &M) override |
| Shut down the asmprinter. More... | |
| void | SetupMachineFunction (MachineFunction &MF) |
| This should be called when a new MachineFunction is being processed from runOnMachineFunction. More... | |
| void | EmitFunctionBody () |
| This method emits the body and trailer for a function. More... | |
| void | emitCFIInstruction (const MachineInstr &MI) |
| void | emitFrameAlloc (const MachineInstr &MI) |
| CFIMoveType | needsCFIMoves () |
| bool | needsSEHMoves () |
| void | EmitJumpTableInfo () |
| Print assembly representations of the jump tables used by the current function to the current output stream. More... | |
| virtual void | EmitGlobalVariable (const GlobalVariable *GV) |
| Emit the specified global variable to the .s file. More... | |
| bool | EmitSpecialLLVMGlobal (const GlobalVariable *GV) |
| Check to see if the specified global is a special global used by LLVM. More... | |
| void | EmitAlignment (unsigned NumBits, const GlobalObject *GO=nullptr) const |
| Emit an alignment directive to the specified power of two boundary. More... | |
| const MCExpr * | lowerConstant (const Constant *CV) |
| Lower the specified LLVM Constant to an MCExpr. More... | |
| void | EmitGlobalConstant (const Constant *CV) |
| Print a general LLVM constant to the .s file. More... | |
| void | computeGlobalGOTEquivs (Module &M) |
| Unnamed constant global variables solely contaning a pointer to another globals variable act like a global variable "proxy", or GOT equivalents, i.e., it's only used to hold the address of the latter. More... | |
| void | emitGlobalGOTEquivs () |
| Constant expressions using GOT equivalent globals may not be eligible for PC relative GOT entry conversion, in such cases we need to emit the proxies we previously omitted in EmitGlobalVariable. More... | |
| virtual void | EmitFunctionBodyStart () |
| Targets can override this to emit stuff before the first basic block in the function. More... | |
| virtual void | EmitBasicBlockStart (const MachineBasicBlock &MBB) const |
| Targets can override this to emit stuff at the start of a basic block. More... | |
| virtual void | EmitBasicBlockEnd (const MachineBasicBlock &MBB) |
| Targets can override this to emit stuff at the end of a basic block. More... | |
| virtual MCSymbol * | GetCPISymbol (unsigned CPID) const |
| Return the symbol for the specified constant pool entry. More... | |
| virtual bool | isBlockOnlyReachableByFallthrough (const MachineBasicBlock *MBB) const |
| Return true if the basic block has exactly one predecessor and the control transfer mechanism between the predecessor and this block is a fall-through. More... | |
| virtual void | emitImplicitDef (const MachineInstr *MI) const |
| Targets can override this to customize the output of IMPLICIT_DEF instructions in verbose mode. More... | |
| MCSymbol * | createTempSymbol (const Twine &Name) const |
| MCSymbol * | getSymbolWithGlobalValueBase (const GlobalValue *GV, StringRef Suffix) const |
| Return the MCSymbol for a private symbol with global value name as its base, with the specified suffix. More... | |
| MCSymbol * | GetExternalSymbolSymbol (StringRef Sym) const |
| Return the MCSymbol for the specified ExternalSymbol. More... | |
| MCSymbol * | GetJTISymbol (unsigned JTID, bool isLinkerPrivate=false) const |
| Return the symbol for the specified jump table entry. More... | |
| MCSymbol * | GetJTSetSymbol (unsigned UID, unsigned MBBID) const |
| Return the symbol for the specified jump table .set FIXME: privatize to AsmPrinter. More... | |
| MCSymbol * | GetBlockAddressSymbol (const BlockAddress *BA) const |
| Return the MCSymbol used to satisfy BlockAddress uses of the specified basic block. More... | |
| MCSymbol * | GetBlockAddressSymbol (const BasicBlock *BB) const |
| void | printOffset (int64_t Offset, raw_ostream &OS) const |
| This is just convenient handler for printing offsets. More... | |
| void | EmitInt8 (int Value) const |
| Emit a byte directive and value. More... | |
| void | EmitInt16 (int Value) const |
| Emit a short directive and value. More... | |
| void | EmitInt32 (int Value) const |
| Emit a long directive and value. More... | |
| void | EmitLabelDifference (const MCSymbol *Hi, const MCSymbol *Lo, unsigned Size) const |
| Emit something like ".long Hi-Lo" where the size in bytes of the directive is specified by Size and Hi/Lo specify the labels. More... | |
| void | EmitLabelPlusOffset (const MCSymbol *Label, uint64_t Offset, unsigned Size, bool IsSectionRelative=false) const |
| Emit something like ".long Label+Offset" where the size in bytes of the directive is specified by Size and Label specifies the label. More... | |
| void | EmitLabelReference (const MCSymbol *Label, unsigned Size, bool IsSectionRelative=false) const |
| Emit something like ".long Label" where the size in bytes of the directive is specified by Size and Label specifies the label. More... | |
| void | EmitSLEB128 (int64_t Value, const char *Desc=nullptr) const |
| Emit the specified signed leb128 value. More... | |
| void | EmitULEB128 (uint64_t Value, const char *Desc=nullptr, unsigned PadTo=0) const |
| Emit the specified unsigned leb128 value. More... | |
| void | EmitCFAByte (unsigned Val) const |
| Emit a .byte 42 directive for a DW_CFA_xxx value. More... | |
| void | EmitEncodingByte (unsigned Val, const char *Desc=nullptr) const |
| Emit a .byte 42 directive that corresponds to an encoding. More... | |
| unsigned | GetSizeOfEncodedValue (unsigned Encoding) const |
| Return the size of the encoding in bytes. More... | |
| void | EmitTTypeReference (const GlobalValue *GV, unsigned Encoding) const |
| Emit reference to a ttype global with a specified encoding. More... | |
| void | emitDwarfSymbolReference (const MCSymbol *Label, bool ForceOffset=false) const |
| Emit a reference to a symbol for use in dwarf. More... | |
| void | emitDwarfStringOffset (DwarfStringPoolEntryRef S) const |
| Emit the 4-byte offset of a string from the start of its section. More... | |
| virtual void | EmitDwarfRegOp (ByteStreamer &BS, const MachineLocation &MLoc) const |
| EmitDwarfRegOp - Emit a dwarf register operation. More... | |
| void | emitCFIInstruction (const MCCFIInstruction &Inst) const |
| Emit frame instruction to describe the layout of the frame. More... | |
| void | emitDwarfAbbrevs (const std::vector< DIEAbbrev * > &Abbrevs) const |
| Emit Dwarf abbreviation table. More... | |
| void | emitDwarfDIE (const DIE &Die) const |
| Recursively emit Dwarf DIE tree. More... | |
| virtual void | PrintSpecial (const MachineInstr *MI, raw_ostream &OS, const char *Code) const |
| Print information related to the specified machine instr that is independent of the operand, and may be independent of the instr itself. More... | |
| virtual void | emitInlineAsmStart () const |
| Let the target do anything it needs to do before emitting inlineasm. More... | |
Public Member Functions inherited from llvm::FunctionPass | |
| FunctionPass (char &pid) | |
| Pass * | createPrinterPass (raw_ostream &O, const std::string &Banner) const override |
| createPrinterPass - Get a function printer pass. More... | |
| void | assignPassManager (PMStack &PMS, PassManagerType T) override |
| Find appropriate Function Pass Manager or Call Graph Pass Manager in the PM Stack and add self into that manager. More... | |
| PassManagerType | getPotentialPassManagerType () const override |
| Return what kind of Pass Manager can manage this pass. More... | |
Public Member Functions inherited from llvm::Pass | |
| Pass (PassKind K, char &pid) | |
| virtual | ~Pass () |
| PassKind | getPassKind () const |
| AnalysisID | getPassID () const |
| getPassID - Return the PassID number that corresponds to this pass. More... | |
| virtual void | print (raw_ostream &O, const Module *M) const |
| print - Print out the internal state of the pass. More... | |
| void | dump () const |
| virtual void | preparePassManager (PMStack &) |
| Check if available pass managers are suitable for this pass or not. More... | |
| void | setResolver (AnalysisResolver *AR) |
| AnalysisResolver * | getResolver () const |
| virtual void | releaseMemory () |
| releaseMemory() - This member can be implemented by a pass if it wants to be able to release its memory when it is no longer needed. More... | |
| virtual void * | getAdjustedAnalysisPointer (AnalysisID ID) |
| getAdjustedAnalysisPointer - This method is used when a pass implements an analysis interface through multiple inheritance. More... | |
| virtual ImmutablePass * | getAsImmutablePass () |
| virtual PMDataManager * | getAsPMDataManager () |
| virtual void | verifyAnalysis () const |
| verifyAnalysis() - This member can be implemented by a analysis pass to check state of analysis information. More... | |
| virtual void | dumpPassStructure (unsigned Offset=0) |
| template<typename AnalysisType > | |
| AnalysisType * | getAnalysisIfAvailable () const |
| getAnalysisIfAvailable<AnalysisType>() - Subclasses use this function to get analysis information that might be around, for example to update it. More... | |
| bool | mustPreserveAnalysisID (char &AID) const |
| mustPreserveAnalysisID - This method serves the same function as getAnalysisIfAvailable, but works if you just have an AnalysisID. More... | |
| template<typename AnalysisType > | |
| AnalysisType & | getAnalysis () const |
| getAnalysis<AnalysisType>() - This function is used by subclasses to get to the analysis information that they claim to use by overriding the getAnalysisUsage function. More... | |
| template<typename AnalysisType > | |
| AnalysisType & | getAnalysis (Function &F) |
| getAnalysis<AnalysisType>() - This function is used by subclasses to get to the analysis information that they claim to use by overriding the getAnalysisUsage function. More... | |
| template<typename AnalysisType > | |
| AnalysisType & | getAnalysisID (AnalysisID PI) const |
| template<typename AnalysisType > | |
| AnalysisType & | getAnalysisID (AnalysisID PI, Function &F) |
Additional Inherited Members | |
Public Types inherited from llvm::AsmPrinter | |
| enum | CFIMoveType { CFI_M_None, CFI_M_EH, CFI_M_Debug } |
| typedef std::pair< const GlobalVariable *, unsigned > | GOTEquivUsePair |
| Map global GOT equivalent MCSymbols to GlobalVariables and keep track of its number of uses by other globals. More... | |
Static Public Member Functions inherited from llvm::Pass | |
| static const PassInfo * | lookupPassInfo (const void *TI) |
| static const PassInfo * | lookupPassInfo (StringRef Arg) |
| static Pass * | createPass (AnalysisID ID) |
Public Attributes inherited from llvm::AsmPrinter | |
| TargetMachine & | TM |
| Target machine description. More... | |
| const MCAsmInfo * | MAI |
| Target Asm Printer information. More... | |
| MCContext & | OutContext |
| This is the context for the output file that we are streaming. More... | |
| std::unique_ptr< MCStreamer > | OutStreamer |
| This is the MCStreamer object for the file we are generating. More... | |
| const MachineFunction * | MF |
| The current machine function. More... | |
| MachineModuleInfo * | MMI |
| This is a pointer to the current MachineModuleInfo. More... | |
| Mangler * | Mang |
| Name-mangler for global names. More... | |
| MCSymbol * | CurrentFnSym |
| The symbol for the current function. More... | |
| MCSymbol * | CurrentFnSymForSize |
| The symbol used to represent the start of the current function for the purpose of calculating its size (e.g. More... | |
| MapVector< const MCSymbol *, GOTEquivUsePair > | GlobalGOTEquivs |
Protected Member Functions inherited from llvm::AsmPrinter | |
| AsmPrinter (TargetMachine &TM, std::unique_ptr< MCStreamer > Streamer) | |
Protected Member Functions inherited from llvm::MachineFunctionPass | |
| MachineFunctionPass (char &ID) | |
| void | getAnalysisUsage (AnalysisUsage &AU) const override |
| getAnalysisUsage - Subclasses that override getAnalysisUsage must call this. More... | |
Protected Member Functions inherited from llvm::FunctionPass | |
| bool | skipOptnoneFunction (const Function &F) const |
| skipOptnoneFunction - This function has Attribute::OptimizeNone and most transformation passes should skip it. More... | |
Definition at line 32 of file ARMAsmPrinter.h.
|
explicit |
Definition at line 60 of file ARMAsmPrinter.cpp.
|
inlineoverridevirtual |
Print to the current output stream assembly representations of the constants in the constant pool MCP.
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.
Reimplemented from llvm::AsmPrinter.
Definition at line 80 of file ARMAsmPrinter.h.
|
overridevirtual |
This virtual method can be overridden by targets that want to emit something at the end of their file.
Reimplemented from llvm::AsmPrinter.
Definition at line 475 of file ARMAsmPrinter.cpp.
References llvm::AsmPrinter::EmitAlignment(), emitNonLazySymbolPointer(), llvm::MachineModuleInfoMachO::GetGVStubList(), llvm::MachineModuleInfoMachO::GetHiddenGVStubList(), llvm::MCObjectFileInfo::getNonLazySymbolPointerSection(), llvm::MachineModuleInfo::getObjFileInfo(), llvm::AsmPrinter::getObjFileLowering(), llvm::TargetMachine::getTargetTriple(), llvm::Triple::isOSBinFormatMachO(), llvm::MCAF_SubsectionsViaSymbols, llvm::AsmPrinter::MMI, llvm::AsmPrinter::OutStreamer, and llvm::AsmPrinter::TM.
|
overridevirtual |
Targets can override this to emit stuff after the last basic block in the function.
Reimplemented from llvm::AsmPrinter.
Definition at line 65 of file ARMAsmPrinter.cpp.
References llvm::MCDR_DataRegionEnd, and llvm::AsmPrinter::OutStreamer.
|
overridevirtual |
EmitFunctionEntryLabel - Emit the label that is the entrypoint for the function.
This can be overridden by targets as required to do custom stuff.
Reimplemented from llvm::AsmPrinter.
Definition at line 74 of file ARMAsmPrinter.cpp.
References llvm::AsmPrinter::CurrentFnSym, llvm::ARMFunctionInfo::isThumbFunction(), llvm::MCAF_Code16, and llvm::AsmPrinter::OutStreamer.
|
overridevirtual |
Let the target do anything it needs to do after emitting inlineasm.
This callback can be used restore the original mode in case the inlineasm contains directives to switch modes. StartInfo - the original subtarget info before inline asm EndInfo - the final subtarget info after parsing the inline asm, or NULL if the value is unknown.
Reimplemented from llvm::AsmPrinter.
Definition at line 421 of file ARMAsmPrinter.cpp.
References isThumb(), llvm::MCAF_Code16, llvm::MCAF_Code32, and llvm::AsmPrinter::OutStreamer.
|
overridevirtual |
Targets should implement this to emit instructions.
CONSTPOOL_ENTRY - This instruction represents a floating constant pool in the function. The first operand is the ID# for this instruction, the second is the index into the MachineConstantPool that this is, the third is the size in bytes of this constant pool entry. The required alignment is specified on the basic block holding this MI.
Reimplemented from llvm::AsmPrinter.
Definition at line 1200 of file ARMAsmPrinter.cpp.
References llvm::MCInstBuilder::addImm(), llvm::MCInst::addOperand(), llvm::MCInstBuilder::addReg(), llvm::ARMCC::AL, llvm::MachineConstantPoolEntry::ConstVal, llvm::convertAddSubFlagsOpcode(), llvm::MCConstantExpr::create(), llvm::MCSymbolRefExpr::create(), llvm::MCBinaryExpr::createAdd(), llvm::MCOperand::createExpr(), llvm::MCOperand::createImm(), llvm::ARMMCExpr::createLower16(), llvm::MCOperand::createReg(), llvm::MCBinaryExpr::createSub(), llvm::MCContext::createTempSymbol(), llvm::ARMMCExpr::createUpper16(), llvm::TargetOpcode::DBG_VALUE, llvm::AsmPrinter::EmitGlobalConstant(), EmitJumpTableAddrs(), EmitJumpTableInsts(), EmitJumpTableTBInst(), EmitMachineConstantPoolValue(), llvm::AsmPrinter::EmitToStreamer(), llvm::MachineInstr::FrameSetup, llvm::MachineConstantPool::getConstants(), llvm::AsmPrinter::GetCPISymbol(), llvm::TargetMachine::getDataLayout(), llvm::MachineInstr::getFlag(), llvm::AsmPrinter::getFunctionNumber(), llvm::MachineOperand::getGlobal(), llvm::MachineOperand::getImm(), llvm::MachineOperand::getIndex(), llvm::MachineInstr::getOpcode(), llvm::MachineInstr::getOperand(), getPICLabel(), llvm::DataLayout::getPrivateGlobalPrefix(), llvm::MachineOperand::getReg(), llvm::MachineOperand::getTargetFlags(), llvm::ARMSubtarget::hasV5TOps(), llvm::MachineConstantPoolEntry::isMachineConstantPoolEntry(), llvm::ARMSubtarget::isTargetEHABICompatible(), llvm::ARMSubtarget::isTargetMachO(), llvm::Label, llvm_unreachable, llvm::LowerARMMachineInstrToMCInst(), llvm::MachineConstantPoolEntry::MachineCPVal, llvm::MCDR_DataRegion, llvm::MCDR_DataRegionEnd, llvm::AsmPrinter::OutContext, llvm::AsmPrinter::OutStreamer, llvm::MCInst::setOpcode(), llvm::AsmPrinter::TM, llvm::ISD::TRAP, and llvm::MachineConstantPoolEntry::Val.
| void ARMAsmPrinter::EmitJumpTableAddrs | ( | const MachineInstr * | MI | ) |
Definition at line 935 of file ARMAsmPrinter.cpp.
References llvm::MCConstantExpr::create(), llvm::MCSymbolRefExpr::create(), llvm::MCBinaryExpr::createAdd(), llvm::MCBinaryExpr::createSub(), llvm::AsmPrinter::EmitAlignment(), llvm::MachineOperand::getIndex(), llvm::MachineFunction::getJumpTableInfo(), llvm::MachineJumpTableInfo::getJumpTables(), llvm::MachineInstr::getOperand(), llvm::TargetMachine::getRelocationModel(), llvm::MachineBasicBlock::getSymbol(), llvm::ARMFunctionInfo::isThumbFunction(), llvm::HexagonISD::JT, llvm::MCDR_DataRegionEnd, llvm::MCDR_DataRegionJT32, llvm::AsmPrinter::MF, llvm::AsmPrinter::OutContext, llvm::AsmPrinter::OutStreamer, llvm::Reloc::PIC_, and llvm::AsmPrinter::TM.
Referenced by EmitInstruction().
| void ARMAsmPrinter::EmitJumpTableInsts | ( | const MachineInstr * | MI | ) |
Definition at line 982 of file ARMAsmPrinter.cpp.
References llvm::ARMCC::AL, llvm::MCSymbolRefExpr::create(), llvm::AsmPrinter::EmitToStreamer(), llvm::MachineOperand::getIndex(), llvm::MachineFunction::getJumpTableInfo(), llvm::MachineJumpTableInfo::getJumpTables(), llvm::MachineInstr::getOperand(), llvm::MachineBasicBlock::getSymbol(), llvm::HexagonISD::JT, llvm::AsmPrinter::MF, llvm::AsmPrinter::OutContext, and llvm::AsmPrinter::OutStreamer.
Referenced by EmitInstruction().
| void ARMAsmPrinter::EmitJumpTableTBInst | ( | const MachineInstr * | MI, |
| unsigned | OffsetWidth | ||
| ) |
Definition at line 1006 of file ARMAsmPrinter.cpp.
References llvm::MCConstantExpr::create(), llvm::MCSymbolRefExpr::create(), llvm::MCBinaryExpr::createAdd(), llvm::MCBinaryExpr::createDiv(), llvm::MCBinaryExpr::createSub(), llvm::AsmPrinter::EmitAlignment(), llvm::AsmPrinter::GetCPISymbol(), llvm::MachineOperand::getImm(), llvm::MachineOperand::getIndex(), llvm::MachineFunction::getJumpTableInfo(), llvm::MachineJumpTableInfo::getJumpTables(), llvm::MachineInstr::getOperand(), llvm::HexagonISD::JT, llvm::MCDR_DataRegionEnd, llvm::MCDR_DataRegionJT16, llvm::MCDR_DataRegionJT8, llvm::AsmPrinter::MF, llvm::AsmPrinter::OutContext, and llvm::AsmPrinter::OutStreamer.
Referenced by EmitInstruction().
|
overridevirtual |
EmitMachineConstantPoolValue - Print a machine constantpool value to the .s file.
Reimplemented from llvm::AsmPrinter.
Definition at line 877 of file ARMAsmPrinter.cpp.
References llvm::MCConstantExpr::create(), llvm::MCSymbolRefExpr::create(), llvm::MCBinaryExpr::createAdd(), llvm::MCBinaryExpr::createSub(), llvm::MCContext::createTempSymbol(), llvm::AsmPrinter::GetBlockAddressSymbol(), llvm::AsmPrinter::getCurExceptionSym(), llvm::TargetMachine::getDataLayout(), llvm::AsmPrinter::GetExternalSymbolSymbol(), llvm::AsmPrinter::getFunctionNumber(), getGV(), llvm::ARMConstantPoolValue::getLabelId(), llvm::ARMConstantPoolValue::getModifier(), getModifierVariantKind(), llvm::ARMConstantPoolValue::getPCAdjustment(), getPICLabel(), llvm::DataLayout::getPrivateGlobalPrefix(), llvm::AsmPrinter::getSymbol(), llvm::MachineBasicBlock::getSymbol(), llvm::MachineConstantPoolValue::getType(), llvm::DataLayout::getTypeAllocSize(), llvm::ARMConstantPoolValue::isBlockAddress(), llvm::ARMConstantPoolValue::isExtSymbol(), llvm::ARMConstantPoolValue::isGlobalValue(), llvm::ARMConstantPoolValue::isLSDA(), llvm::ARMConstantPoolValue::isMachineBasicBlock(), llvm::ARMSubtarget::isTargetMachO(), llvm::ARMII::MO_NONLAZY, llvm::ARMConstantPoolValue::mustAddCurrentAddress(), llvm::AsmPrinter::OutContext, llvm::AsmPrinter::OutStreamer, and llvm::AsmPrinter::TM.
Referenced by EmitInstruction().
|
overridevirtual |
This virtual method can be overridden by targets that want to emit something at the start of their file.
Reimplemented from llvm::AsmPrinter.
Definition at line 431 of file ARMAsmPrinter.cpp.
References llvm::Triple::ARMSubArch_v6m, llvm::Triple::ARMSubArch_v7m, llvm::Triple::getArch(), llvm::Module::getModuleInlineAsm(), llvm::Triple::getSubArch(), llvm::TargetMachine::getTargetTriple(), llvm::Triple::isOSBinFormatELF(), isThumb(), llvm::MCAF_Code16, llvm::MCAF_SyntaxUnified, llvm::AsmPrinter::OutStreamer, llvm::Triple::thumb, llvm::Triple::thumbeb, and llvm::AsmPrinter::TM.
Targets can override this to change how global constants that are part of a C++ static/global constructor list are emitted.
Reimplemented from llvm::AsmPrinter.
Definition at line 83 of file ARMAsmPrinter.cpp.
References llvm::MCSymbolRefExpr::create(), llvm::dyn_cast(), llvm::TargetMachine::getDataLayout(), llvm::Value::getType(), llvm::DataLayout::getTypeAllocSize(), llvm::ARMSubtarget::isTargetELF(), llvm::ARMII::MO_NO_FLAG, llvm::AsmPrinter::OutContext, llvm::AsmPrinter::OutStreamer, llvm::Constant::stripPointerCasts(), llvm::AsmPrinter::TM, llvm::MCSymbolRefExpr::VK_ARM_TARGET1, and llvm::MCSymbolRefExpr::VK_None.
|
inlineoverridevirtual |
Get the value for DW_AT_APPLE_isa. Zero if no isa encoding specified.
Reimplemented from llvm::AsmPrinter.
Definition at line 106 of file ARMAsmPrinter.h.
References llvm::Triple::ARMSubArch_v6m, llvm::Triple::ARMSubArch_v7m, llvm::ARM::DW_ISA_ARM_arm, llvm::ARM::DW_ISA_ARM_thumb, llvm::Triple::getArch(), llvm::Triple::getSubArch(), llvm::TargetMachine::getTargetTriple(), llvm::Triple::isOSBinFormatMachO(), isThumb(), llvm::Triple::thumb, and llvm::Triple::thumbeb.
|
inlineoverridevirtual |
getPassName - Return a nice clean name for a pass.
This usually implemented in terms of the name that is registered by one of the Registration templates, but can be overloaded directly.
Reimplemented from llvm::Pass.
Definition at line 58 of file ARMAsmPrinter.h.
| bool ARMAsmPrinter::lowerOperand | ( | const MachineOperand & | MO, |
| MCOperand & | MCOp | ||
| ) |
Definition at line 68 of file ARMMCInstLower.cpp.
References llvm::APFloat::convert(), llvm::APFloat::convertToDouble(), llvm::MCSymbolRefExpr::create(), llvm::MCOperand::createExpr(), llvm::MCOperand::createFPImm(), llvm::MCOperand::createImm(), llvm::MCOperand::createReg(), llvm::MachineOperand::getBlockAddress(), llvm::AsmPrinter::GetBlockAddressSymbol(), llvm::AsmPrinter::GetCPISymbol(), llvm::AsmPrinter::GetExternalSymbolSymbol(), llvm::MachineOperand::getFPImm(), llvm::MachineOperand::getGlobal(), llvm::MachineOperand::getImm(), llvm::MachineOperand::getIndex(), llvm::AsmPrinter::GetJTISymbol(), llvm::MachineOperand::getMBB(), llvm::MachineOperand::getReg(), llvm::MachineOperand::getSubReg(), llvm::MachineBasicBlock::getSymbol(), llvm::MachineOperand::getSymbolName(), llvm::MachineOperand::getTargetFlags(), llvm::MachineOperand::getType(), llvm::ConstantFP::getValueAPF(), llvm::APFloat::IEEEdouble, llvm::MachineOperand::isImplicit(), llvm_unreachable, llvm::MachineOperand::MO_BlockAddress, llvm::MachineOperand::MO_ConstantPoolIndex, llvm::MachineOperand::MO_ExternalSymbol, llvm::MachineOperand::MO_FPImmediate, llvm::MachineOperand::MO_GlobalAddress, llvm::MachineOperand::MO_Immediate, llvm::MachineOperand::MO_JumpTableIndex, llvm::MachineOperand::MO_MachineBasicBlock, llvm::MachineOperand::MO_Register, llvm::MachineOperand::MO_RegisterMask, llvm::AsmPrinter::OutContext, and llvm::APFloat::rmTowardZero.
Referenced by llvm::LowerARMMachineInstrToMCInst().
|
overridevirtual |
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 from llvm::AsmPrinter.
Definition at line 392 of file ARMAsmPrinter.cpp.
References llvm::MachineInstr::getOperand(), llvm::MachineOperand::getReg(), llvm::ARMInstPrinter::getRegisterName(), and llvm::MachineOperand::isReg().
|
overridevirtual |
Print the specified operand of MI, an INLINEASM instruction, using the specified assembler variant.
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.
Targets should override this to format as appropriate.
Reimplemented from llvm::AsmPrinter.
Definition at line 217 of file ARMAsmPrinter.cpp.
References contains(), llvm::MachineOperand::getImm(), llvm::InlineAsm::getNumOperandRegisters(), llvm::MachineInstr::getNumOperands(), llvm::MachineInstr::getOperand(), llvm::MachineInstr::getParent(), llvm::MachineBasicBlock::getParent(), llvm::MachineOperand::getReg(), llvm::TargetSubtargetInfo::getRegisterInfo(), llvm::ARMInstPrinter::getRegisterName(), llvm::MCRegisterInfo::getSubReg(), llvm::MachineFunction::getSubtarget(), llvm::InlineAsm::hasRegClassConstraint(), llvm::MachineOperand::isImm(), llvm::MachineOperand::isReg(), llvm::InlineAsm::isUseOperandTiedToDef(), llvm::MCRegisterInfo::DiffListIterator::isValid(), llvm::AsmPrinter::MF, llvm::InlineAsm::MIOp_FirstOperand, llvm::AsmPrinter::PrintAsmOperand(), and printOperand().
| void ARMAsmPrinter::printOperand | ( | const MachineInstr * | MI, |
| int | OpNum, | ||
| raw_ostream & | O | ||
| ) |
Definition at line 146 of file ARMAsmPrinter.cpp.
References contains(), llvm::AsmPrinter::GetCPISymbol(), llvm::MachineOperand::getGlobal(), llvm::MachineOperand::getImm(), llvm::MachineOperand::getIndex(), llvm::MachineOperand::getMBB(), llvm::MachineOperand::getOffset(), llvm::MachineInstr::getOperand(), llvm::MachineInstr::getParent(), llvm::MachineBasicBlock::getParent(), llvm::MachineOperand::getReg(), llvm::TargetSubtargetInfo::getRegisterInfo(), llvm::ARMInstPrinter::getRegisterName(), llvm::MachineOperand::getSubReg(), llvm::MCRegisterInfo::getSubReg(), llvm::MachineFunction::getSubtarget(), llvm::MachineBasicBlock::getSymbol(), llvm::MachineOperand::getTargetFlags(), llvm::MachineOperand::getType(), llvm::TargetRegisterInfo::isPhysicalRegister(), llvm_unreachable, llvm::AsmPrinter::MAI, llvm::AsmPrinter::MF, llvm::MachineOperand::MO_ConstantPoolIndex, llvm::MachineOperand::MO_GlobalAddress, llvm::ARMII::MO_HI16, llvm::MachineOperand::MO_Immediate, llvm::ARMII::MO_LO16, llvm::MachineOperand::MO_MachineBasicBlock, llvm::ARMII::MO_PLT, llvm::MachineOperand::MO_Register, llvm::Pass::print(), llvm::MCSymbol::print(), and llvm::AsmPrinter::printOffset().
Referenced by PrintAsmOperand().
|
overridevirtual |
runOnMachineFunction - This uses the EmitInstruction() method to print assembly for each instruction.
Reimplemented from llvm::AsmPrinter.
Definition at line 103 of file ARMAsmPrinter.cpp.
References llvm::ARMCC::AL, llvm::AsmPrinter::CurrentFnSym, llvm::AsmPrinter::EmitAlignment(), llvm::AsmPrinter::EmitFunctionBody(), llvm::AsmPrinter::EmitToStreamer(), llvm::MachineFunction::getConstantPool(), llvm::MachineFunction::getFunction(), llvm::MachineFunction::getInfo(), llvm::MachineFunction::getSubtarget(), llvm::GlobalValue::hasInternalLinkage(), llvm::COFF::IMAGE_SYM_CLASS_EXTERNAL, llvm::COFF::IMAGE_SYM_CLASS_STATIC, llvm::COFF::IMAGE_SYM_DTYPE_FUNCTION, llvm::ARMSubtarget::isTargetCOFF(), llvm::MCAF_Code16, llvm::AsmPrinter::OutStreamer, llvm::COFF::SCT_COMPLEX_TYPE_SHIFT, and llvm::AsmPrinter::SetupMachineFunction().
1.8.6