[NIOS2] Fix disassembly of br.n instruction.
authorHafiz Abid Qadeer <abidh@codesourcery.com>
Wed, 24 Mar 2021 21:24:35 +0000 (21:24 +0000)
committerHafiz Abid Qadeer <abidh@codesourcery.com>
Thu, 25 Mar 2021 10:52:14 +0000 (10:52 +0000)
commitefa30ac3c504d24c55733a627abe49bd0368cf67
tree546cf1df9b817a8cf13f445069f53feb26d603d7
parent5e74b4959bdeb5660c5e6f3e7a293269043a9a67
[NIOS2] Fix disassembly of br.n instruction.

The code was checking wrong bit for sign extension. It caused it
to zero-extend instead of sign-extend the immediate value.

2021-03-25  Abid Qadeer  <abidh@codesourcery.com>

opcodes/
* nios2-dis.c (nios2_print_insn_arg): Fix sign extension of
immediate in br.n instruction.

gas/
* testsuite/gas/nios2/brn.s: New.
* testsuite/gas/nios2/brn.d: New.
gas/ChangeLog
gas/testsuite/gas/nios2/brn.d [new file with mode: 0644]
gas/testsuite/gas/nios2/brn.s [new file with mode: 0644]
opcodes/ChangeLog
opcodes/nios2-dis.c