ΒΆbool constrainSelectedInstRegOperands(
    llvm::MachineInstr& I,
    const llvm::TargetInstrInfo& TII,
    const llvm::TargetRegisterInfo& TRI,
    const llvm::RegisterBankInfo& RBI)

Description

Mutate the newly-selected instruction \p I to constrain its (possibly generic) virtual register operands to the instruction's register class. This could involve inserting COPYs before (for uses) or after (for defs). This requires the number of operands to match the instruction description.

Declared at: llvm/include/llvm/CodeGen/GlobalISel/Utils.h:138

Parameters

llvm::MachineInstr& I
const llvm::TargetInstrInfo& TII
const llvm::TargetRegisterInfo& TRI
const llvm::RegisterBankInfo& RBI

Returns

whether operand regclass constraining succeeded.