17 #ifndef LLVM_LIB_MC_MCDISASSEMBLER_DISASSEMBLER_H 18 #define LLVM_LIB_MC_MCDISASSEMBLER_DISASSEMBLER_H 45 std::string TripleName;
63 std::unique_ptr<const llvm::MCAsmInfo> MAI;
65 std::unique_ptr<const llvm::MCRegisterInfo> MRI;
67 std::unique_ptr<const llvm::MCSubtargetInfo> MSI;
69 std::unique_ptr<const llvm::MCInstrInfo> MII;
71 std::unique_ptr<const llvm::MCContext> Ctx;
73 std::unique_ptr<const llvm::MCDisassembler> DisAsm;
75 std::unique_ptr<llvm::MCInstPrinter> IP;
93 : TripleName(
std::move(tripleName)), DisInfo(disInfo), TagType(tagType),
94 GetOpInfo(getOpInfo), SymbolLookUp(symbolLookUp), TheTarget(theTarget),
95 Options(0), CommentStream(CommentsToEmit) {
101 DisAsm.reset(disAsm);
120 void addOptions(uint64_t Options) { this->Options |= Options; }
122 void setCPU(
const char *CPU) { this->CPU = CPU; }
void setIP(MCInstPrinter *NewIP)
This class represents lattice values for constants.
Superclass for all disassemblers.
A raw_ostream that writes to an SmallVector or SmallString.
LLVMSymbolLookupCallback getSymbolLookupCallback() const
LLVMOpInfoCallback getGetOpInfo() const
void * getDisInfo() const
int(* LLVMOpInfoCallback)(void *DisInfo, uint64_t PC, uint64_t Offset, uint64_t Size, int TagType, void *TagBuf)
The type for the operand information call back function.
LLVMDisasmContext(std::string tripleName, void *disInfo, int tagType, LLVMOpInfoCallback getOpInfo, LLVMSymbolLookupCallback symbolLookUp, const Target *theTarget, const MCAsmInfo *mAI, const MCRegisterInfo *mRI, const MCSubtargetInfo *mSI, const MCInstrInfo *mII, llvm::MCContext *ctx, const MCDisassembler *disAsm, MCInstPrinter *iP)
const MCRegisterInfo * getRegisterInfo() const
Context object for machine code objects.
raw_svector_ostream CommentStream
MCRegisterInfo base class - We assume that the target defines a static array of MCRegisterDesc object...
This class is intended to be used as a base class for asm properties and features specific to the tar...
Interface to description of machine instruction set.
const MCSubtargetInfo * getSubtargetInfo() const
const MCInstrInfo * getInstrInfo() const
const MCRegisterDesc & get(unsigned RegNo) const
Provide a get method, equivalent to [], but more useful with a pointer to this object.
const MCAsmInfo * getAsmInfo() const
const Target * getTarget() const
Target - Wrapper for Target specific information.
This is an instance of a target assembly language printer that converts an MCInst to valid target ass...
uint64_t getOptions() const
const MCInstrDesc & get(unsigned Opcode) const
Return the machine instruction descriptor that corresponds to the specified instruction opcode...
Generic base class for all target subtargets.
void addOptions(uint64_t Options)
void setCPU(const char *CPU)
const std::string & getTripleName() const
StringRef - Represent a constant reference to a string, i.e.
const MCDisassembler * getDisAsm() const
const char *(* LLVMSymbolLookupCallback)(void *DisInfo, uint64_t ReferenceValue, uint64_t *ReferenceType, uint64_t ReferencePC, const char **ReferenceName)
The type for the symbol lookup function.
SmallString< 128 > CommentsToEmit