LLVM 22.0.0git
|
Interface to description of machine instruction set. More...
#include "llvm/MC/MCInstrInfo.h"
Public Types | |
using | ComplexDeprecationPredicate |
Public Member Functions | |
void | InitMCInstrInfo (const MCInstrDesc *D, const unsigned *NI, const char *ND, const uint8_t *DF, const ComplexDeprecationPredicate *CDI, unsigned NO, const int16_t *RCHWTables=nullptr, int16_t NumRegClassByHwMode=0) |
Initialize MCInstrInfo, called by TableGen auto-generated routines. | |
unsigned | getNumOpcodes () const |
const int16_t * | getRegClassByHwModeTable (unsigned ModeId) const |
int16_t | getOpRegClassID (const MCOperandInfo &OpInfo, unsigned HwModeId) const |
Return the ID of the register class to use for OpInfo , for the active HwMode HwModeId . | |
const MCInstrDesc & | get (unsigned Opcode) const |
Return the machine instruction descriptor that corresponds to the specified instruction opcode. | |
StringRef | getName (unsigned Opcode) const |
Returns the name for the instructions with the given opcode. | |
LLVM_ABI bool | getDeprecatedInfo (MCInst &MI, const MCSubtargetInfo &STI, std::string &Info) const |
Returns true if a certain instruction is deprecated and if so returns the reason in Info . |
Protected Attributes | |
const int16_t * | RegClassByHwModeTables |
int16_t | NumRegClassByHwModes |
Interface to description of machine instruction set.
Definition at line 27 of file MCInstrInfo.h.
Definition at line 29 of file MCInstrInfo.h.
|
inline |
Return the machine instruction descriptor that corresponds to the specified instruction opcode.
Definition at line 90 of file MCInstrInfo.h.
References assert().
Referenced by llvm::CombinerHelper::applyCombineMulToShl(), llvm::MachineIRBuilder::buildInstrNoInsert(), llvm::MCSchedModel::computeInstrLatency(), llvm::TargetInstrInfo::createPHIDestinationCopy(), llvm::TargetInstrInfo::createPHISourceCopy(), DecodePredicateOperand(), llvm::NVPTXFrameLowering::emitPrologue(), expandPseudoVFMK(), llvm::TargetInstrInfo::foldMemoryOperand(), getCondFromBranch(), llvm::HexagonMCInstrInfo::getDesc(), llvm::LLVMDisasmContext::getInstrInfo(), llvm::TargetInstrInfo::getInstrLatency(), llvm::AMDGPUDisassembler::getMCII(), llvm::TargetInstrInfo::getOperandLatency(), llvm::MCSchedModel::getReciprocalThroughput(), llvm::HexagonMCInstrInfo::getType(), hasType(), llvm::ARM_MC::isCPSRDefined(), isPCRel32Branch(), llvm::ARM_MC::isPredicated(), isPrefix(), isRIPRelative(), llvm::HexagonMCInstrInfo::isSolo(), llvm::RISCVLegalizerInfo::legalizeCustom(), llvm::TargetInstrInfo::lowerCopy(), printMasking(), llvm::AMDGPU::supportsScaleOffset(), and llvm::LegalizerInfo::verify().
bool MCInstrInfo::getDeprecatedInfo | ( | MCInst & | MI, |
const MCSubtargetInfo & | STI, | ||
std::string & | Info ) const |
Returns true if a certain instruction is deprecated and if so returns the reason in Info
.
Definition at line 15 of file MCInstrInfo.cpp.
References llvm::MCSubtargetInfo::getFeatureBits(), and MI.
Returns the name for the instructions with the given opcode.
Definition at line 97 of file MCInstrInfo.h.
References assert().
Referenced by createAtomicLibcall(), llvm::createMemLibcall(), llvm::fuseInstructionPair(), getInstructionID(), llvm::HexagonMCInstrInfo::getName(), and llvm::LegalizerInfo::verify().
|
inline |
Definition at line 69 of file MCInstrInfo.h.
|
inline |
Return the ID of the register class to use for OpInfo
, for the active HwMode HwModeId
.
In general TargetInstrInfo's version which is already specialized to the subtarget should be used.
Definition at line 80 of file MCInstrInfo.h.
References getRegClassByHwModeTable().
Definition at line 71 of file MCInstrInfo.h.
References assert(), NumRegClassByHwModes, and RegClassByHwModeTables.
Referenced by getOpRegClassID().
|
inline |
Initialize MCInstrInfo, called by TableGen auto-generated routines.
DO NOT USE.
Definition at line 54 of file MCInstrInfo.h.
References D(), DF, NumRegClassByHwModes, and RegClassByHwModeTables.
|
protected |
Definition at line 49 of file MCInstrInfo.h.
Referenced by getRegClassByHwModeTable(), and InitMCInstrInfo().
|
protected |
Definition at line 48 of file MCInstrInfo.h.
Referenced by getRegClassByHwModeTable(), and InitMCInstrInfo().