The FT32's disassembly of 10-bit literals has the incorrect mask.

[opcodes]
	* ft32-dis.c (print_insn_ft32): Fix incorrect data field mask.
This commit is contained in:
jamesbowman 2015-09-25 12:33:30 -07:00
parent 19ba03f495
commit 9a09557a93
2 changed files with 5 additions and 1 deletions

View file

@ -1,3 +1,7 @@
2015-09-25 James Bowman <james.bowman@ftdichip.com>
* ft32-dis.c (print_insn_ft32): Fix incorrect data field mask.
2015-09-23 Nick Clifton <nickc@redhat.com>
PR binutils/15835

View file

@ -118,7 +118,7 @@ print_insn_ft32 (bfd_vma addr, struct disassemble_info *info)
case FT32_FLD_RIMM:
imm = (iword >> FT32_FLD_RIMM_BIT) & ((1 << FT32_FLD_RIMM_SIZ) - 1);
if (imm & 0x400)
info->print_address_func ((bfd_vma) imm & 0x1ff, info);
info->print_address_func ((bfd_vma) imm & 0x3ff, info);
else
fpr(stream, "$r%d", imm & 0x1f);
break;