[LLVMdev] MI.getNumOperands() < MI.getDesc().getNumOperands()
Jakob Stoklund Olesen
stoklund at 2pi.dk
Wed Feb 3 12:34:51 CST 2010
On Feb 3, 2010, at 7:55 AM, Edmund Grimley Evans wrote:
> With a modified copy of LLVM (so it's probably my fault) I'm getting
> an assertion failure because isTwoAddrUse (in
> TwoAddressInstructionPass.cpp) is being called with a MachineInstr MI
> such that MI.getNumOperands() is 2, but MI.getDesc().getNumOperands()
> is 5. The assertion fails when that function calls MI.getOperand(2).
Why does your instruction only have 2 operands when the description says it should have 5? That should never happen except when first building the instruction.
More information about the LLVMdev