Emitting machine code
The MC layer is responsible for emitting machine code in textual or binary form. Most of the functionality is either implemented in the various MC classes and only needs to be configured, or the implementation is generated from the target description.
The initialization of the MC layer takes place in the MCTargetDesc/M88kMCTargetDesc.cpp
file. The following classes are registered with the TargetRegistry
singleton:
M88kMCAsmInfo
: This class provides basic information, such as the size of a code pointer, the direction of stack growth, the comment symbol, or the name of assembler directives.M88MCInstrInfo
: This class holds information about instructions, for example, the name of an instruction.M88kRegInfo
: This class provides information about registers, for example, the name of a register, or which register is the stack pointer.M88kSubtargetInfo
: This class holds the data of the scheduling model and the methods to parse and set CPU features...