Skip to content

Commit

Permalink
arm: add missing operand info for Thumb instruction LDR involving lab…
Browse files Browse the repository at this point in the history
…el. bug reported by Daniel Colascione
  • Loading branch information
aquynh committed Jun 1, 2014
1 parent 6eb55cf commit bb71c13
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions arch/ARM/ARMInstPrinter.c
Original file line number Diff line number Diff line change
Expand Up @@ -660,6 +660,15 @@ static void printThumbLdrLabelOperand(MCInst *MI, unsigned OpNum, SStream *O)
}

SStream_concat(O, "]%s", markup(">"));

if (MI->csh->detail) {
MI->flat_insn.arm.operands[MI->flat_insn.arm.op_count].type = ARM_OP_MEM;
MI->flat_insn.arm.operands[MI->flat_insn.arm.op_count].mem.base = ARM_REG_PC;
MI->flat_insn.arm.operands[MI->flat_insn.arm.op_count].mem.index = ARM_REG_INVALID;
MI->flat_insn.arm.operands[MI->flat_insn.arm.op_count].mem.scale = 1;
MI->flat_insn.arm.operands[MI->flat_insn.arm.op_count].mem.disp = OffImm;
MI->flat_insn.arm.op_count++;
}
}

// so_reg is a 4-operand unit corresponding to register forms of the A5.1
Expand Down

0 comments on commit bb71c13

Please sign in to comment.