llvm::MachineInstr::getRegClassConstraint

Compute the static register class constraint for operand OpIdx. For normal instructions, this is derived from the MCInstrDesc. For inline assembly it is derived from the flag words.

Synopsis

Declared in <llvm/CodeGen/MachineInstr.h>

TargetRegisterClass const*
getRegClassConstraint(
    unsigned int OpIdx,
    TargetInstrInfo const* TII,
    TargetRegisterInfo const* TRI) const;

Description

Returns NULL if the static register class constraint cannot be determined.

Parameters

NameDescription
TIITargetInstrInfo - Interface to description of machine instruction set
TRITargetRegisterInfo base class - We assume that the target defines a static array of TargetRegisterDesc objects that represent all of the machine registers that the target has. As such, we simply have to track a pointer to this array so that we can turn register number into a register descriptor.