arc: Detect usage of illegal double register pairs
authorClaudiu Zissulescu <claziss@gmail.com>
Tue, 14 Jul 2020 11:51:15 +0000 (14:51 +0300)
committerClaudiu Zissulescu <claziss@gmail.com>
Tue, 14 Jul 2020 11:51:15 +0000 (14:51 +0300)
commit570b0ed6d5368f4653bf019c60fa277ed7e983bf
tree396601d110cffb36b44f2395bcec4b14a3f0efe7
parentbfbd943845684ac374c41797154d2c53cc338145
arc: Detect usage of illegal double register pairs

ARC can use odd-even double register pairs in some selected
instructions. Although the GNU assembler doesn't allow even-odd
registers to be used, there may be cases when the disassembler is
presented with such situation.  This patch add a test and detects such
cases.

opcodes/
2020-07-14  Claudiu Zissulescu  <claziss@gmail.com>

* arc-dis.c (print_insn_arc): Detect and emit a warning when a
faulty double register pair is detected.

binutils/
2020-07-14  Claudiu Zissulescu  <claziss@gmail.com>

* testsuite/binutils-all/arc/double_regs.s: New test.
* testsuite/binutils-all/arc/objdump.exp: Add the above test.

Signed-off-by: Claudiu Zissulescu <claziss@gmail.com>
binutils/ChangeLog
binutils/testsuite/binutils-all/arc/double_regs.s [new file with mode: 0644]
binutils/testsuite/binutils-all/arc/objdump.exp
opcodes/ChangeLog
opcodes/arc-dis.c