14 #ifndef LLVM_TARGET_TARGETMACHINE_H
15 #define LLVM_TARGET_TARGETMACHINE_H
26 class InstrItineraryData;
34 class TargetLibraryInfo;
35 class TargetFrameLowering;
36 class TargetInstrInfo;
37 class TargetIntrinsicInfo;
40 class TargetPassConfig;
41 class TargetRegisterInfo;
42 class TargetSelectionDAGInfo;
43 class TargetSubtargetInfo;
44 class ScalarTargetTransformInfo;
45 class VectorTargetTransformInfo;
46 class formatted_raw_ostream;
51 class PassManagerBase;
53 using legacy::PassManagerBase;
324 bool DisableVerify =
true,
336 bool DisableVerify =
true);
346 bool DisableVerify =
true);
virtual const TargetLowering * getTargetLowering() const
unsigned PrintMachineCode
void setMCUseCFI(bool Value)
setMCUseCFI - Set whether all we should use dwarf's .cfi_* directives.
Reloc::Model getRelocationModel() const
virtual bool addPassesToEmitFile(PassManagerBase &PM, formatted_raw_ostream &Out, CodeGenFileType FileType, bool DisableVerify=true, AnalysisID StartAfter=0, AnalysisID StopAfter=0)
const StringRef getTargetFeatureString() const
const StringRef getTargetCPU() const
void setMCNoExecStack(bool Value)
setMCNoExecStack - Set whether an executabel stack is not needed.
virtual bool addPassesToEmitMachineCode(PassManagerBase &, JITCodeEmitter &, bool=true)
virtual TargetPassConfig * createPassConfig(PassManagerBase &PM)
virtual const TargetSelectionDAGInfo * getSelectionDAGInfo() const
bool hasMCRelaxAll() const
void resetTargetOptions(const MachineFunction *MF) const
Reset the target options based on the function's attributes.
void setOptLevel(CodeGenOpt::Level Level) const
Overrides the optimization level.
const MCAsmInfo * getMCAsmInfo() const
unsigned MCUseDwarfDirectory
virtual const InstrItineraryData * getInstrItineraryData() const
const MCAsmInfo * AsmInfo
void setMCUseDwarfDirectory(bool Value)
unsigned MCSaveTempLabels
bool hasMCSaveTempLabels() const
CodeGenOpt::Level getOptLevel() const
virtual const TargetSubtargetInfo * getSubtargetImpl() const
CodeModel::Model getCodeModel() const
virtual bool addPassesToEmitMC(PassManagerBase &PM, MCContext *&Ctx, raw_ostream &OS, bool DisableVerify=true)
virtual bool addPassesToEmitFile(PassManagerBase &, formatted_raw_ostream &, CodeGenFileType, bool=true, AnalysisID=0, AnalysisID=0)
static bool getAsmVerbosityDefault()
virtual bool addPassesToEmitMachineCode(PassManagerBase &PM, JITCodeEmitter &MCE, bool DisableVerify=true)
static bool getDataSections()
static bool getFunctionSections()
static void setAsmVerbosityDefault(bool)
const Target & TheTarget
TheTarget - The Target that this machine was created for.
virtual const TargetFrameLowering * getFrameLowering() const
virtual bool addCodeEmitter(PassManagerBase &, JITCodeEmitter &)
virtual TargetJITInfo * getJITInfo()
LLVMTargetMachine(const Target &T, StringRef TargetTriple, StringRef CPU, StringRef FS, TargetOptions Options, Reloc::Model RM, CodeModel::Model CM, CodeGenOpt::Level OL)
virtual void addAnalysisPasses(PassManagerBase &)
Register analysis passes for this target with a pass manager.
virtual const TargetInstrInfo * getInstrInfo() const
const STC & getSubtarget() const
MCCodeGenInfo * CodeGenInfo
void setFastISel(bool Enable)
virtual void addAnalysisPasses(PassManagerBase &PM)
Register analysis passes for this target with a pass manager.
#define LLVM_DELETED_FUNCTION
virtual bool addPassesToEmitMC(PassManagerBase &, MCContext *&, raw_ostream &, bool=true)
const StringRef getTargetTriple() const
virtual const TargetIntrinsicInfo * getIntrinsicInfo() const
virtual const DataLayout * getDataLayout() const
void setMCRelaxAll(bool Value)
cl::opt< std::string > StopAfter("stop-after", cl::desc("Stop compilation after a specific pass"), cl::value_desc("pass-name"), cl::init(""))
cl::opt< std::string > StartAfter("start-after", cl::desc("Resume compilation after a specific pass"), cl::value_desc("pass-name"), cl::init(""))
virtual const TargetRegisterInfo * getRegisterInfo() const
cl::opt< TargetMachine::CodeGenFileType > FileType("filetype", cl::init(TargetMachine::CGFT_AssemblyFile), cl::desc("Choose a file type (not all types are supported by all targets):"), cl::values(clEnumValN(TargetMachine::CGFT_AssemblyFile,"asm","Emit an assembly ('.s') file"), clEnumValN(TargetMachine::CGFT_ObjectFile,"obj","Emit a native object ('.o') file"), clEnumValN(TargetMachine::CGFT_Null,"null","Emit nothing, for performance testing"), clEnumValEnd))
bool shouldPrintMachineCode() const
bool hasMCUseCFI() const
hasMCUseCFI - Check whether we should use dwarf's .cfi_* directives.
TLSModel::Model getTLSModel(const GlobalValue *GV) const
bool hasMCUseLoc() const
hasMCUseLoc - Check whether we should use dwarf's .loc directive.
bool hasMCNoExecStack() const
hasMCNoExecStack - Check whether an executable stack is not needed.
bool hasMCUseDwarfDirectory() const
LLVM Value Representation.
static void setDataSections(bool)
setDataSections - Set if the data are emit into separate sections.
const Target & getTarget() const
static void setFunctionSections(bool)
void setMCUseLoc(bool Value)
setMCUseLoc - Set whether all we should use dwarf's .loc directive.
void setMCSaveTempLabels(bool Value)