LLVM API Documentation

Functions
X86AsmPrinter.cpp File Reference
#include "X86AsmPrinter.h"
#include "InstPrinter/X86ATTInstPrinter.h"
#include "MCTargetDesc/X86BaseInfo.h"
#include "X86InstrInfo.h"
#include "X86MachineFunctionInfo.h"
#include "llvm/ADT/SmallString.h"
#include "llvm/CodeGen/MachineConstantPool.h"
#include "llvm/CodeGen/MachineModuleInfoImpls.h"
#include "llvm/CodeGen/MachineValueType.h"
#include "llvm/CodeGen/TargetLoweringObjectFileImpl.h"
#include "llvm/IR/DebugInfo.h"
#include "llvm/IR/DerivedTypes.h"
#include "llvm/IR/Mangler.h"
#include "llvm/IR/Module.h"
#include "llvm/IR/Type.h"
#include "llvm/MC/MCAsmInfo.h"
#include "llvm/MC/MCContext.h"
#include "llvm/MC/MCExpr.h"
#include "llvm/MC/MCSectionCOFF.h"
#include "llvm/MC/MCSectionMachO.h"
#include "llvm/MC/MCStreamer.h"
#include "llvm/MC/MCSymbol.h"
#include "llvm/Support/COFF.h"
#include "llvm/Support/Debug.h"
#include "llvm/Support/ErrorHandling.h"
#include "llvm/Support/TargetRegistry.h"
Include dependency graph for X86AsmPrinter.cpp:

Go to the source code of this file.

Functions

static void printSymbolOperand (X86AsmPrinter &P, const MachineOperand &MO, raw_ostream &O)
static void printOperand (X86AsmPrinter &P, const MachineInstr *MI, unsigned OpNo, raw_ostream &O, const char *Modifier=nullptr, unsigned AsmVariant=0)
static void printPCRelImm (X86AsmPrinter &P, const MachineInstr *MI, unsigned OpNo, raw_ostream &O)
static void printLeaMemReference (X86AsmPrinter &P, const MachineInstr *MI, unsigned Op, raw_ostream &O, const char *Modifier=nullptr)
static void printMemReference (X86AsmPrinter &P, const MachineInstr *MI, unsigned Op, raw_ostream &O, const char *Modifier=nullptr)
static void printIntelMemReference (X86AsmPrinter &P, const MachineInstr *MI, unsigned Op, raw_ostream &O, const char *Modifier=nullptr, unsigned AsmVariant=1)
static bool printAsmMRegister (X86AsmPrinter &P, const MachineOperand &MO, char Mode, raw_ostream &O)
static void emitNonLazySymbolPointer (MCStreamer &OutStreamer, MCSymbol *StubLabel, MachineModuleInfoImpl::StubValueTy &MCSym)
void LLVMInitializeX86AsmPrinter ()

Function Documentation

static void emitNonLazySymbolPointer ( MCStreamer OutStreamer,
MCSymbol StubLabel,
MachineModuleInfoImpl::StubValueTy MCSym 
) [static]

Definition at line 751 of file X86AsmPrinter.cpp.

References llvm::TheX86_32Target, llvm::TheX86_64Target, llvm::X, and Y.

static bool printAsmMRegister ( X86AsmPrinter P,
const MachineOperand MO,
char  Mode,
raw_ostream O 
) [static]
static void printIntelMemReference ( X86AsmPrinter P,
const MachineInstr MI,
unsigned  Op,
raw_ostream O,
const char *  Modifier = nullptr,
unsigned  AsmVariant = 1 
) [static]
static void printLeaMemReference ( X86AsmPrinter P,
const MachineInstr MI,
unsigned  Op,
raw_ostream O,
const char *  Modifier = nullptr 
) [static]
static void printMemReference ( X86AsmPrinter P,
const MachineInstr MI,
unsigned  Op,
raw_ostream O,
const char *  Modifier = nullptr 
) [static]
static void printOperand ( X86AsmPrinter P,
const MachineInstr MI,
unsigned  OpNo,
raw_ostream O,
const char *  Modifier = nullptr,
unsigned  AsmVariant = 0 
) [static]
static void printPCRelImm ( X86AsmPrinter P,
const MachineInstr MI,
unsigned  OpNo,
raw_ostream O 
) [static]

printPCRelImm - This is used to print an immediate value that ends up being encoded as a pc-relative value. These print slightly differently, for example, a $ is not emitted.

Definition at line 185 of file X86AsmPrinter.cpp.

References llvm::MachineOperand::getImm(), llvm::MachineInstr::getOperand(), llvm::MachineOperand::getType(), llvm_unreachable, llvm::MachineOperand::MO_GlobalAddress, llvm::MachineOperand::MO_Immediate, llvm::MachineOperand::MO_Register, printOperand(), and printSymbolOperand().

Referenced by llvm::X86AsmPrinter::PrintAsmOperand().

static void printSymbolOperand ( X86AsmPrinter P,
const MachineOperand MO,
raw_ostream O 
) [static]

printSymbolOperand - Print a raw symbol reference operand. This handles jump tables, constant pools, global address and external symbols, all of which print to a label with various suffixes for relocation types etc.

Definition at line 77 of file X86AsmPrinter.cpp.

References llvm::X86AsmPrinter::GetCPISymbol(), llvm::MachineOperand::getGlobal(), llvm::MachineOperand::getIndex(), llvm::MCSymbol::getName(), llvm::MachineModuleInfo::getObjFileInfo(), llvm::MachineOperand::getOffset(), llvm::MCContext::GetOrCreateSymbol(), llvm::MachineFunction::getPICBaseSymbol(), llvm::PointerIntPair< PointerTy, IntBits, IntType, PtrTraits >::getPointer(), llvm::AsmPrinter::getSymbol(), llvm::AsmPrinter::getSymbolWithGlobalValueBase(), llvm::MachineOperand::getTargetFlags(), llvm::MachineOperand::getType(), llvm::GlobalValue::hasInternalLinkage(), llvm_unreachable, llvm::AsmPrinter::MF, llvm::AsmPrinter::MMI, llvm::MachineOperand::MO_ConstantPoolIndex, llvm::X86II::MO_DARWIN_HIDDEN_NONLAZY_PIC_BASE, llvm::X86II::MO_DARWIN_NONLAZY, llvm::X86II::MO_DARWIN_NONLAZY_PIC_BASE, llvm::X86II::MO_DARWIN_STUB, llvm::X86II::MO_DLLIMPORT, llvm::X86II::MO_DTPOFF, llvm::MachineOperand::MO_GlobalAddress, llvm::X86II::MO_GOT, llvm::X86II::MO_GOT_ABSOLUTE_ADDRESS, llvm::X86II::MO_GOTNTPOFF, llvm::X86II::MO_GOTOFF, llvm::X86II::MO_GOTPCREL, llvm::X86II::MO_GOTTPOFF, llvm::X86II::MO_INDNTPOFF, llvm::X86II::MO_NO_FLAG, llvm::X86II::MO_NTPOFF, llvm::X86II::MO_PIC_BASE_OFFSET, llvm::X86II::MO_PLT, llvm::X86II::MO_SECREL, llvm::X86II::MO_TLSGD, llvm::X86II::MO_TLSLD, llvm::X86II::MO_TLSLDM, llvm::X86II::MO_TLVP, llvm::X86II::MO_TLVP_PIC_BASE, llvm::X86II::MO_TPOFF, llvm::AsmPrinter::OutContext, and llvm::AsmPrinter::printOffset().

Referenced by llvm::X86AsmPrinter::PrintAsmOperand(), printLeaMemReference(), printOperand(), and printPCRelImm().