26 #define DEBUG_TYPE "wasm-mc-target-desc" 28 #define GET_INSTRINFO_MC_DESC 29 #include "WebAssemblyGenInstrInfo.inc" 31 #define GET_SUBTARGETINFO_MC_DESC 32 #include "WebAssemblyGenSubtargetInfo.inc" 34 #define GET_REGINFO_MC_DESC 35 #include "WebAssemblyGenRegisterInfo.inc" 44 InitWebAssemblyMCInstrInfo(X);
50 InitWebAssemblyMCRegisterInfo(X, 0);
55 unsigned SyntaxVariant,
59 assert(SyntaxVariant == 0 &&
"WebAssembly only has one syntax variant");
78 return createWebAssemblyMCSubtargetInfoImpl(TT, CPU, FS);
static MCInstrInfo * createMCInstrInfo()
static GCMetadataPrinterRegistry::Add< ErlangGCPrinter > X("erlang", "erlang-compatible garbage collector")
This class represents lattice values for constants.
static MCTargetStreamer * createObjectTargetStreamer(MCStreamer &S, const MCSubtargetInfo &STI)
This class prints an WebAssembly MCInst to wasm file syntax.
Target specific streamer interface.
static void RegisterMCInstPrinter(Target &T, Target::MCInstPrinterCtorTy Fn)
RegisterMCInstPrinter - Register a MCInstPrinter implementation for the given target.
static MCAsmBackend * createAsmBackend(const Target &, const MCSubtargetInfo &STI, const MCRegisterInfo &, const MCTargetOptions &)
static void RegisterAsmTargetStreamer(Target &T, Target::AsmTargetStreamerCtorTy Fn)
const Triple & getTargetTriple() const
Context object for machine code objects.
wasm::ValType toValType(const MVT &Ty)
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...
This part is for null output.
static MCTargetStreamer * createAsmTargetStreamer(MCStreamer &S, formatted_raw_ostream &OS, MCInstPrinter *, bool)
static void RegisterMCAsmBackend(Target &T, Target::MCAsmBackendCtorTy Fn)
RegisterMCAsmBackend - Register a MCAsmBackend implementation for the given target.
Streaming machine code generation interface.
unsigned const MachineRegisterInfo * MRI
MCCodeEmitter * createWebAssemblyMCCodeEmitter(const MCInstrInfo &MCII)
MCCodeEmitter - Generic instruction encoding interface.
This file provides WebAssembly-specific target descriptions.
Interface to description of machine instruction set.
static MCRegisterInfo * createMCRegisterInfo(const Triple &)
static MCCodeEmitter * createCodeEmitter(const MCInstrInfo &MCII, const MCRegisterInfo &, MCContext &Ctx)
This part is for ascii assembly output.
static void RegisterMCSubtargetInfo(Target &T, Target::MCSubtargetInfoCtorFnTy Fn)
RegisterMCSubtargetInfo - Register a MCSubtargetInfo implementation for the given target...
static void RegisterObjectTargetStreamer(Target &T, Target::ObjectTargetStreamerCtorTy Fn)
#define llvm_unreachable(msg)
Marks that the current location is not supposed to be reachable.
Triple - Helper class for working with autoconf configuration names.
This file declares WebAssembly-specific target streamer classes.
static MCSubtargetInfo * createMCSubtargetInfo(const Triple &TT, StringRef CPU, StringRef FS)
static MCTargetStreamer * createNullTargetStreamer(MCStreamer &S)
static void RegisterMCCodeEmitter(Target &T, Target::MCCodeEmitterCtorTy Fn)
RegisterMCCodeEmitter - Register a MCCodeEmitter implementation for the given target.
MCAsmBackend * createWebAssemblyAsmBackend(const Triple &TT)
static void RegisterMCRegInfo(Target &T, Target::MCRegInfoCtorFnTy Fn)
RegisterMCRegInfo - Register a MCRegisterInfo implementation for the given target.
Target - Wrapper for Target specific information.
This file contains the declaration of the WebAssemblyMCAsmInfo class.
This is an instance of a target assembly language printer that converts an MCInst to valid target ass...
static void RegisterMCInstrInfo(Target &T, Target::MCInstrInfoCtorFnTy Fn)
RegisterMCInstrInfo - Register a MCInstrInfo implementation for the given target. ...
This part is for Wasm object output.
Generic base class for all target subtargets.
void LLVMInitializeWebAssemblyTargetMC()
assert(ImpDefSCC.getReg()==AMDGPU::SCC &&ImpDefSCC.isDef())
static MCInstPrinter * createMCInstPrinter(const Triple &, unsigned SyntaxVariant, const MCAsmInfo &MAI, const MCInstrInfo &MII, const MCRegisterInfo &MRI)
RegisterMCAsmInfoFn - Helper template for registering a target assembly info implementation.
static void RegisterNullTargetStreamer(Target &T, Target::NullTargetStreamerCtorTy Fn)
Generic interface to target specific assembler backends.
static MCAsmInfo * createMCAsmInfo(const MCRegisterInfo &, const Triple &TT)
StringRef - Represent a constant reference to a string, i.e.
Target & getTheWebAssemblyTarget32()
Target & getTheWebAssemblyTarget64()