llvm::CSEMIRBuilder::buildInstr

buildInstr overloads

Synopses

Declared in <llvm/CodeGen/GlobalISel/CSEMIRBuilder.h>

Build and insert <empty> = Opcode <empty>. The insertion point is the one set by the last call of either setBasicBlock or setMI.

MachineInstrBuilder
buildInstr(unsigned int Opcode);
» more...

Build and insert an instruction, CSEing when possible.

virtual
MachineInstrBuilder
buildInstr(
    unsigned int Opc,
    ArrayRef<DstOp> DstOps,
    ArrayRef<SrcOp> SrcOps,
    std::optional<unsigned int> Flag = std::nullopt) override;
» more...

Return Value

  • a MachineInstrBuilder for the newly created instruction.
  • A MachineInstrBuilder for the built or reused instruction.

Parameters

NameDescription
OpcodeTarget opcode for the instruction.
OpcOpcode of the instruction to build.
DstOpsDestination operands.
SrcOpsSource operands.
FlagOptional instruction flags.

Preconditions

  • setBasicBlock or setMI must have been called.