18 CodeEmitter::EncodingInfo
19 CodeEmitter::getOrCreateEncodingInfo(
unsigned MCID) {
24 SmallVector<llvm::MCFixup, 2>
Fixups;
25 const MCInst &Inst = Sequence[MCID];
26 MCInst Relaxed(Sequence[MCID]);
30 EI.first = Code.
size();
32 EI.second = Code.
size() - EI.first;
This class represents lattice values for constants.
virtual bool mayNeedRelaxation(const MCInst &Inst, const MCSubtargetInfo &STI) const =0
Check whether the given instruction may need relaxation.
virtual void relaxInstruction(const MCInst &Inst, const MCSubtargetInfo &STI, MCInst &Res) const =0
Relax the instruction in the given fragment to the next wider instruction.
std::pair< UnicodeEncodingForm, unsigned > EncodingInfo
EncodingInfo - Holds the encoding type and length of the byte order mark if it exists.
virtual void encodeInstruction(const MCInst &Inst, raw_ostream &OS, SmallVectorImpl< MCFixup > &Fixups, const MCSubtargetInfo &STI) const =0
EncodeInstruction - Encode the given Inst to bytes on the output stream OS.
A utility class used to compute instruction encodings.